]> source.dussan.org Git - jquery.git/commitdiff
Fixed a bug in jQuery.speed(), when there's no properties provided.
authorJohn Resig <jeresig@gmail.com>
Wed, 10 Jan 2007 00:46:10 +0000 (00:46 +0000)
committerJohn Resig <jeresig@gmail.com>
Wed, 10 Jan 2007 00:46:10 +0000 (00:46 +0000)
src/fx/fx.js

index 30bedbfab8442a368e026d38427ac7ab8ccd2406..0ede5eea9ed402743643709d5610b8c430b308ee 100644 (file)
@@ -356,9 +356,9 @@ jQuery.fn.extend({
 jQuery.extend({
        
        speed: function(speed, easing, fn) {
-               var opt = speed.constructor == Object ? speed : {
+               var opt = speed && speed.constructor == Object ? speed : {
                        complete: fn || !fn && easing || 
-                               speed.constructor == Function && speed,
+                               speed && speed.constructor == Function && speed,
                        duration: speed,
                        easing: fn && easing || easing && easing.constructor != Function && easing
                };