Skip to content

Commit

Permalink
fixup! fix(router): fix URL serialization so special characters are o…
Browse files Browse the repository at this point in the history
…nly encoded where needed
  • Loading branch information
jasonaden committed Feb 21, 2018
1 parent 6c6af62 commit 36319d2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/router/src/url_tree.ts
Original file line number Diff line number Diff line change
Expand Up @@ -337,7 +337,7 @@ function serializeSegment(segment: UrlSegmentGroup, root: boolean): string {
* sub-delims = "!" / "$" / "&" / "'" / "(" / ")"
* / "*" / "+" / "," / ";" / "="
*/
function encodeUriString(s: string, type: 'query' | 'segment' = 'query'): string {
function encodeUriString(s: string): string {
return encodeURIComponent(s)
.replace(/%40/g, '@')
.replace(/%3A/gi, ':')
Expand Down

0 comments on commit 36319d2

Please sign in to comment.