Fixed a loop that only worked in webkit.
authorjaubourg <aubourg.julian@gmail.com>
Mon, 20 Dec 2010 23:56:00 +0000 (00:56 +0100)
committerjaubourg <j@ubourg.net>
Fri, 31 Dec 2010 03:02:33 +0000 (04:02 +0100)
src/core.js

index 79ea5ce..d141c4d 100644 (file)
@@ -800,7 +800,7 @@ jQuery.extend({
                        deferred  = {
                                
                                // then( f1, f2, ...)
-                               then: function() {
+                               then: function then() {
                                        
                                        if ( ! cancelled ) {
                                        
@@ -820,7 +820,7 @@ jQuery.extend({
                                                        elem = args[ i ];
                                                        type = jQuery.type( elem );
                                                        if ( type === "array" ) {
-                                                               deferred.then.apply( deferred , elem );
+                                                               then.apply( this , elem );
                                                        } else if ( type === "function" ) {
                                                                callbacks.push( elem );
                                                        }