]> source.dussan.org Git - jquery.git/commitdiff
Moved readyList check.
authorjeresig <jeresig@gmail.com>
Thu, 17 Dec 2009 04:09:55 +0000 (23:09 -0500)
committerjeresig <jeresig@gmail.com>
Thu, 17 Dec 2009 04:09:55 +0000 (23:09 -0500)
src/core.js

index 0d5588c269b4eecadc2e81c31afcabc73c32dda0..8f81c520ecba388156ae8f7f9a9a007a255b1286 100644 (file)
@@ -224,12 +224,12 @@ jQuery.fn = jQuery.prototype = {
                jQuery.bindReady();
 
                // If the DOM is already ready
-               if ( jQuery.isReady && !readyList ) {
+               if ( jQuery.isReady ) {
                        // Execute the function immediately
                        fn.call( document, jQuery );
 
                // Otherwise, remember the function for later
-               } else {
+               } else if ( readyList ) {
                        // Add the function to the wait list
                        readyList.push( fn );
                }