Aieeeeee!! removeClass bug fixed. I'm so dumb.

This commit is contained in:
John Resig 2006-05-02 19:03:07 +00:00
parent 0ababc8fea
commit facb2324f9

4
jquery/jquery.js vendored
View File

@ -108,9 +108,7 @@ function $(a,c) {
}, },
removeClass: function(c) { removeClass: function(c) {
return this.each(function(){ return this.each(function(){
if ( c == null ) this.className = c == null ? '' :
this.className = '';
else
this.className.replace( this.className.replace(
new RegExp('(^|\\s*\\b[^-])'+c+'($|\\b(?=[^-]))', 'g'), ''); new RegExp('(^|\\s*\\b[^-])'+c+'($|\\b(?=[^-]))', 'g'), '');
}); });