Avoid isIterateeCall check if floating is a boolean.

This commit is contained in:
John-David Dalton
2015-12-20 12:38:48 -06:00
parent 4b77b7a8b3
commit f42446d22f

View File

@@ -11648,7 +11648,7 @@
* // => a floating-point number between 1.2 and 5.2
*/
function random(min, max, floating) {
if (floating && isIterateeCall(min, max, floating)) {
if (floating && typeof floating != 'boolean' && isIterateeCall(min, max, floating)) {
max = floating = undefined;
}
var noMin = min === undefined,