Skip to content

Commit f8d4ce9

Browse files
committed
Fix the example of path compile in README.
1 parent 447fb23 commit f8d4ce9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Readme.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ var toPath = pathToRegexp.compile('/user/:id')
171171

172172
toPath({ id: 123 }) //=> "/user/123"
173173
toPath({ id: 'café' }) //=> "/user/caf%C3%A9"
174-
toPath({ id: '/' }) //=> "%2F"
174+
toPath({ id: '/' }) //=> "/user/%2F"
175175

176176
var toPathRepeated = pathToRegexp.compile('/:segment+')
177177

0 commit comments

Comments
 (0)