From 1039d66c73f8f54aec9be5357dce6e9280b2cc69 Mon Sep 17 00:00:00 2001 From: Yessiest Date: Wed, 18 Oct 2023 17:15:05 +0400 Subject: [PATCH] Fixed an indexing bug in filepath --- lib/landline/node.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/landline/node.rb b/lib/landline/node.rb index 0e870dc..5d87cf7 100644 --- a/lib/landline/node.rb +++ b/lib/landline/node.rb @@ -43,7 +43,8 @@ module Landline request.push_state path, splat, param = @pattern.match(request.path) - do_filepath(request, request.path.delete_suffix(path)) + do_filepath(request, request.path.delete_suffix('/') + .delete_suffix(path)) request.path = path request.splat.append(*splat) request.param.merge!(param)