Cleanup baseFill.

This commit is contained in:
Xotic750
2015-11-04 01:20:10 +01:00
committed by John-David Dalton
parent b9b94609f5
commit 9db252e55d

View File

@@ -2403,7 +2403,7 @@
function baseFill(array, value, start, end) {
var length = array.length;
start = start == null ? 0 : toInteger(start);
start = toInteger(start);
if (start < 0) {
start = -start > length ? 0 : (length + start);
}
@@ -2411,10 +2411,8 @@
if (end < 0) {
end += length;
}
length = start > end ? 0 : (end >>> 0);
start >>>= 0;
while (start < length) {
end = start > end ? 0 : toLength(end);
while (start < end) {
array[start++] = value;
}
return array;