diff options
author | Jason Bedard <jason+github@jbedard.ca> | 2017-12-12 22:43:30 -0800 |
---|---|---|
committer | Jason Bedard <jason+github@jbedard.ca> | 2018-01-15 09:26:19 -0800 |
commit | 3d732cca6b5076a9d13eee98e2b075b37384cd91 (patch) | |
tree | 7ad2375d276c212e7d252554b3f87e5b0b3bec5e /src/core | |
parent | 6c38ebbd47c6b0fa654733819bd5ae36c1ac6c48 (diff) | |
download | jquery-3d732cca6b5076a9d13eee98e2b075b37384cd91.tar.gz jquery-3d732cca6b5076a9d13eee98e2b075b37384cd91.zip |
Core: deprecate jQuery.isFunction
Fixes gh-3609
Diffstat (limited to 'src/core')
-rw-r--r-- | src/core/access.js | 7 | ||||
-rw-r--r-- | src/core/init.js | 7 | ||||
-rw-r--r-- | src/core/ready-no-deferred.js | 7 |
3 files changed, 12 insertions, 9 deletions
diff --git a/src/core/access.js b/src/core/access.js index 86cdbc7e6..2e1eb4121 100644 --- a/src/core/access.js +++ b/src/core/access.js @@ -1,6 +1,7 @@ define( [ - "../core" -], function( jQuery ) { + "../core", + "../var/isFunction" +], function( jQuery, isFunction ) { "use strict"; @@ -22,7 +23,7 @@ var access = function( elems, fn, key, value, chainable, emptyGet, raw ) { } else if ( value !== undefined ) { chainable = true; - if ( !jQuery.isFunction( value ) ) { + if ( !isFunction( value ) ) { raw = true; } diff --git a/src/core/init.js b/src/core/init.js index 8841264de..8865238c8 100644 --- a/src/core/init.js +++ b/src/core/init.js @@ -2,10 +2,11 @@ define( [ "../core", "../var/document", + "../var/isFunction", "./var/rsingleTag", "../traversing/findFilter" -], function( jQuery, document, rsingleTag ) { +], function( jQuery, document, isFunction, rsingleTag ) { "use strict"; @@ -63,7 +64,7 @@ var rootjQuery, for ( match in context ) { // Properties of context are called as methods if possible - if ( jQuery.isFunction( this[ match ] ) ) { + if ( isFunction( this[ match ] ) ) { this[ match ]( context[ match ] ); // ...and otherwise set as attributes @@ -106,7 +107,7 @@ var rootjQuery, // HANDLE: $(function) // Shortcut for document ready - } else if ( jQuery.isFunction( selector ) ) { + } else if ( isFunction( selector ) ) { return root.ready !== undefined ? root.ready( selector ) : diff --git a/src/core/ready-no-deferred.js b/src/core/ready-no-deferred.js index a7722ae9a..4428020ef 100644 --- a/src/core/ready-no-deferred.js +++ b/src/core/ready-no-deferred.js @@ -1,7 +1,8 @@ define( [ "../core", - "../var/document" -], function( jQuery, document ) { + "../var/document", + "../var/isFunction" +], function( jQuery, document, isFunction ) { "use strict"; @@ -52,7 +53,7 @@ jQuery.extend( { while ( readyCallbacks.length ) { fn = readyCallbacks.shift(); - if ( jQuery.isFunction( fn ) ) { + if ( isFunction( fn ) ) { executeReady( fn ); } } |