Aieeeeee!! removeClass bug fixed. I'm so dumb.
[jquery.git] / jquery / jquery.js
index 66588f5..b9cb311 100644 (file)
@@ -1,7 +1,9 @@
 /*
- * JQuery (http://jquery.com/)
- * By John Resig (http://ejohn.org/)
- * Under an Attribution, Share Alike License
+ * jQuery (jquery.com)
+ *
+ * Copyright (c) 2006 John Resig (ejohn.org)
+ * Licensed under the MIT License:
+ *   http://www.opensource.org/licenses/mit-license.php
  *
  * $Date$
  * $Rev$
@@ -67,13 +69,14 @@ function $(a,c) {
                },
                
                css: function(a,b) {
-                       return this.each(function(){
-                               if ( !b )
-                                       for ( var j in a )
-                                               $.attr(this.style,j,a[j]);
-                               else
-                                       $.attr(this.style,a,b);
-                       });
+                       return  a.constructor != String || b ?
+                               this.each(function(){
+                                       if ( !b )
+                                               for ( var j in a )
+                                                       $.attr(this.style,j,a[j]);
+                                       else
+                                               $.attr(this.style,a,b);
+                               }) : $.css( this.get(0), a );
                },
                toggle: function() {
                        return this.each(function(){
@@ -753,4 +756,4 @@ $.fn.text = function(e) {
 setTimeout(function(){
        if ( typeof Prototype != "undefined" && $.g == null && $.clean == null )
                throw "Error: You are overwriting jQuery, please include jQuery last.";
-}, 1000);
\ No newline at end of file
+}, 1000);