Skip to content

Commit

Permalink
Fixes _.isNaN for wrapped numbers #2
Browse files Browse the repository at this point in the history
  • Loading branch information
Damon Hunt authored and Damon Hunt committed Aug 3, 2015
1 parent 72caece commit 9829e0d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion underscore.js
Original file line number Diff line number Diff line change
Expand Up @@ -1301,7 +1301,7 @@

// Is the given value `NaN`? (NaN is the only number which does not equal itself).
_.isNaN = function(obj) {
return _.isNumber(obj) && obj != +obj;
return _.isNumber(obj) && isNaN(obj);
};

// Is a given value a boolean?
Expand Down

0 comments on commit 9829e0d

Please sign in to comment.