Merge pull request #220 from giscloud/removeclass_fix

Fix of the L.DomUtil.removeClasss method.
This commit is contained in:
Vladimir Agafonkin 2011-07-31 06:34:55 -07:00
commit b46a9d2eb0

View File

@ -86,7 +86,7 @@ L.DomUtil = {
},
removeClass: function(el, name) {
el.className = el.className.replace(/(\w+)\s*/g, function(w, match) {
el.className = el.className.replace(/(\S+)\s*/g, function(w, match) {
if (match == name) return '';
return w;
}).replace(/^\s+/, '');