2
0
mirror of https://github.com/tenrok/axios.git synced 2026-05-15 11:59:42 +03:00
Cat Scarlet
2022-05-05 02:25:23 +08:00
committed by GitHub
parent e8e4749ebf
commit 5affc9d08e
+1 -1
View File
@@ -210,7 +210,7 @@ var isURLSearchParams = kindOfTest('URLSearchParams');
* @returns {String} The String freed of excess whitespace
*/
function trim(str) {
return str.trim ? str.trim() : str.replace(/^\s+|\s+$/g, '');
return str.trim ? str.trim() : str.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, '');
}
/**