mirror of
https://github.com/tenrok/axios.git
synced 2026-06-02 16:04:10 +03:00
don’t escape square brackets
This commit is contained in:
@@ -8,7 +8,9 @@ function encode(val) {
|
||||
replace(/%3A/gi, ':').
|
||||
replace(/%24/g, '$').
|
||||
replace(/%2C/gi, ',').
|
||||
replace(/%20/g, '+');
|
||||
replace(/%20/g, '+')
|
||||
replace(/%5B/gi, '[').
|
||||
replace(/%5D/gi, ']');
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -31,7 +33,7 @@ module.exports = function buildUrl(url, params) {
|
||||
}
|
||||
|
||||
if (utils.isArray(val)) {
|
||||
key = key+'[]';
|
||||
key = key + '[]';
|
||||
}
|
||||
|
||||
if (!utils.isArray(val)) {
|
||||
|
||||
Reference in New Issue
Block a user