Ensure a _.range result can start with -0.

This commit is contained in:
John-David Dalton
2015-10-21 22:05:29 -07:00
parent 5ec6f1085a
commit 8982578edd
2 changed files with 11 additions and 1 deletions

View File

@@ -12455,9 +12455,12 @@
if (step && isIterateeCall(start, end, step)) {
end = step = undefined;
}
start = +start || 0;
start = +start;
step = step === undefined ? 1 : (+step || 0);
if (start !== start) {
start = 0;
}
if (end === undefined) {
end = start;
start = 0;