2
0
mirror of https://github.com/tenrok/axios.git synced 2026-06-14 18:42:33 +03:00

Allow unsetting headers by passing null (#382) (#1845)

Co-authored-by: Jay <jasonsaayman@gmail.com>
This commit is contained in:
Martti Laine
2020-06-04 20:57:54 +02:00
committed by GitHub
parent 4b3947aa59
commit 487941663b
4 changed files with 33 additions and 6 deletions
+5
View File
@@ -294,6 +294,11 @@ function deepMerge(/* obj1, obj2, obj3, ... */) {
}
}
var lastArgument = arguments[arguments.length - 1];
if (lastArgument === null || typeof lastArgument === 'undefined') {
return lastArgument;
}
for (var i = 0, l = arguments.length; i < l; i++) {
forEach(arguments[i], assignValue);
}