Skip to content

Commit dc9a133

Browse files
committed
Merge pull request #65 from lijunle/patch-1
Fix the example of path compile in README.
2 parents 447fb23 + f8d4ce9 commit dc9a133

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)