mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-06 01:47:48 +00:00
merging mrjjwright's isBoolean, with tests, docs, and credit
This commit is contained in:
@@ -527,7 +527,7 @@
|
||||
|
||||
// Is a given value a boolean?
|
||||
_.isBoolean = function(obj) {
|
||||
return (toString.call(obj) === '[object Boolean]');
|
||||
return obj === true || obj === false;
|
||||
};
|
||||
|
||||
// Is a given value a date?
|
||||
|
||||
Reference in New Issue
Block a user