Fix test fails on old Android & Safari.

This commit is contained in:
John-David Dalton
2014-11-08 09:28:47 -08:00
parent 30f0232d71
commit a2330fb630

View File

@@ -7461,10 +7461,13 @@
* // => false
*/
function isNative(value) {
if (typeof value == 'function' || toString.call(value) == funcClass) {
if (value == null) {
return false;
}
if (toString.call(value) == funcClass) {
return reNative.test(fnToString.call(value));
}
return (value && typeof value == 'object' &&
return (typeof value == 'object' &&
(isHostObject(value) ? reNative : reHostCtor).test(value)) || false;
}