We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bcb9461 commit a026c18Copy full SHA for a026c18
lib/grape/router.rb
@@ -5,7 +5,7 @@ class Router
5
attr_reader :map, :compiled
6
7
def self.normalize_path(path)
8
- return '/'.dup unless path
+ return +'/' unless path
9
10
# Fast path for the overwhelming majority of paths that don't need to be normalized
11
return path.dup if path == '/' || (path.start_with?('/') && !path.end_with?('/') && !path.match?(%r{%|//}))
0 commit comments