diff --git a/jquery.removeClass.js b/jquery.removeClass.js
index 08e0e95..4636434 100644
--- a/jquery.removeClass.js
+++ b/jquery.removeClass.js
@@ -16,7 +16,7 @@
}
}
} else {
- removeClass.call(this, value);
+ removeClass.apply(this, Array.prototype.slice.apply(arguments));
}
return this;
}
diff --git a/test/index.html b/test/index.html
index 0466c43..16192ac 100644
--- a/test/index.html
+++ b/test/index.html
@@ -4,7 +4,7 @@
jquery.removeClass and jquery.hasClass tests
-
+
diff --git a/test/removeClass.test.js b/test/removeClass.test.js
index 707f37b..0b72275 100644
--- a/test/removeClass.test.js
+++ b/test/removeClass.test.js
@@ -41,3 +41,9 @@ test("string", function() {
elem.removeClass("disabled state-open");
equal(elem[0].className, "");
});
+
+test("empty params", function() {
+ var elem = jQuery("");
+ elem.removeClass();
+ equal(elem[0].className, "");
+});
\ No newline at end of file