mirror of
https://github.com/jquery/jquery.git
synced 2024-11-23 02:54:22 +00:00
Tests: fix tests in AMD mode
This commit is contained in:
parent
5d3a968e03
commit
fa793bee20
@ -10,7 +10,7 @@ define( [
|
||||
|
||||
"./core/init",
|
||||
"./selector"
|
||||
], function( jQuery, document, isFunction, documentElement, rnothtmlwhite,
|
||||
], function( jQuery, document, documentElement, isFunction, rnothtmlwhite,
|
||||
slice, dataPriv, nodeName ) {
|
||||
|
||||
"use strict";
|
||||
|
@ -3,11 +3,11 @@ define( function() {
|
||||
|
||||
return function isFunction( obj ) {
|
||||
|
||||
// Support: Chrome <=57, Firefox <=52
|
||||
// In some browsers, typeof returns "function" for HTML <object> elements
|
||||
// (i.e., `typeof document.createElement( "object" ) === "function"`).
|
||||
// We don't want to classify *any* DOM node as a function.
|
||||
return typeof obj === "function" && typeof obj.nodeType !== "number";
|
||||
};
|
||||
// Support: Chrome <=57, Firefox <=52
|
||||
// In some browsers, typeof returns "function" for HTML <object> elements
|
||||
// (i.e., `typeof document.createElement( "object" ) === "function"`).
|
||||
// We don't want to classify *any* DOM node as a function.
|
||||
return typeof obj === "function" && typeof obj.nodeType !== "number";
|
||||
};
|
||||
|
||||
} );
|
||||
|
Loading…
Reference in New Issue
Block a user