]> source.dussan.org Git - jquery.git/commitdiff
Fixed animating to 0% (Bug #1586).
authorJohn Resig <jeresig@gmail.com>
Sat, 15 Sep 2007 03:26:33 +0000 (03:26 +0000)
committerJohn Resig <jeresig@gmail.com>
Sat, 15 Sep 2007 03:26:33 +0000 (03:26 +0000)
src/fx.js

index d75f3d0b0c6d15449b2d4e2870da5e609b542340..a143df6835642bf9cea14749b7af0f8a963e824e 100644 (file)
--- a/src/fx.js
+++ b/src/fx.js
@@ -105,8 +105,8 @@ jQuery.fn.extend({
 
                                                // We need to compute starting value
                                                if ( unit != "px" ) {
-                                                       self.style[ name ] = end + unit;
-                                                       start = (end / e.cur(true)) * start;
+                                                       self.style[ name ] = (end || 1) + unit;
+                                                       start = ((end || 1) / e.cur(true)) * start;
                                                        self.style[ name ] = start + unit;
                                                }