From 47fb48d8e0d726a820e7d5ddc6fd9641f5706c21 Mon Sep 17 00:00:00 2001 From: Madeorsk Date: Sat, 12 Apr 2025 12:16:19 +0200 Subject: [PATCH] Remove unused clone function. --- src/route.zig | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/src/route.zig b/src/route.zig index 8aba123..1ae75b3 100644 --- a/src/route.zig +++ b/src/route.zig @@ -50,18 +50,6 @@ pub const RoutingResult = struct { try self.params.put(try self.allocator.dupe(u8, key), try self.allocator.dupe(u8, value)); } - /// Clone the given result to a new result pointer. - pub fn clone(self: *Self) !*Self - { - const cloned = try Self.init(self.allocator, self.route, self.handler); - cloned.params = try self.params.clone(); - cloned.notFoundHandler = self.notFoundHandler; - cloned.preHandlers = try self.preHandlers.clone(); - cloned.postHandlers = try self.postHandlers.clone(); - cloned.errorHandlers = try self.errorHandlers.clone(); - return cloned; - } - /// Initialize a routing result. pub fn init(allocator: std.mem.Allocator, route: *RouteNode, handler: router.RouteHandler) !*Self {