git.asbjorn.biz
/
jquery.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
904b1c3
)
Extra spaces weren't being removed with removeClass - but I haven't found a good...
author
John Resig
<jeresig@gmail.com>
Mon, 10 Apr 2006 06:09:16 +0000
(06:09 +0000)
committer
John Resig
<jeresig@gmail.com>
Mon, 10 Apr 2006 06:09:16 +0000
(06:09 +0000)
jquery/jquery.js
patch
|
blob
|
history
diff --git
a/jquery/jquery.js
b/jquery/jquery.js
index
668a592
..
07fcdff
100644
(file)
--- a/
jquery/jquery.js
+++ b/
jquery/jquery.js
@@
-106,7
+106,9
@@
function $(a,c) {
},
removeClass: function(c) {
return this.each(function(){
- this.className = c == null ? '' :
+ if ( c == null )
+ this.className = '';
+ else
this.className.replace(
new RegExp('(^|\\s*\\b[^-])'+c+'($|\\b(?=[^-]))', 'g'), '');
});