2
0
mirror of https://github.com/tenrok/axios.git synced 2026-06-05 16:42:32 +03:00

Don't use utils.forEach to loop over arguments

This fixes IE8 support, where we cannot relialably detect an arguments
object.
This commit is contained in:
Colin Timmermans
2015-10-13 19:14:58 +02:00
parent 11c12b2c65
commit 1e2cb9bdca
3 changed files with 31 additions and 66 deletions
-13
View File
@@ -11,18 +11,6 @@ describe('utils::forEach', function () {
expect(sum).toEqual(15);
});
it('should loop over arguments', function () {
var sum = 0;
(function () {
forEach(arguments, function (val) {
sum += val;
});
})(1, 2, 3, 4, 5);
expect(sum).toEqual(15);
});
it('should loop over object keys', function () {
var keys = '';
var vals = 0;
@@ -61,4 +49,3 @@ describe('utils::forEach', function () {
expect(count).toEqual(1);
});
});