Update url_search_params.ts

Values need to be encoded on `toString()`
Closes #7686
This commit is contained in:
Pete Boere 2016-03-21 10:14:13 +00:00 committed by Misko Hevery
parent 0795dd307b
commit 6f3a6a55a0
1 changed files with 2 additions and 1 deletions

View File

@ -122,7 +122,8 @@ export class URLSearchParams {
toString(): string {
var paramsList: string[] = [];
this.paramsMap.forEach((values, k) => { values.forEach(v => paramsList.push(k + '=' + v)); });
this.paramsMap.forEach(
(values, k) => { values.forEach(v => paramsList.push(k + '=' + encodeURIComponent(v))); });
return paramsList.join('&');
}