##// END OF EJS Templates
remove length test add_class and remove_class
Jonathan Frederic -
Show More
@@ -261,17 +261,11 b' function(widget_manager, underscore, backbone){'
261 261 },
262 262
263 263 add_class: function (selector, class_list) {
264 var elements = this._get_selector_element(selector);
265 if (elements.length > 0) {
266 elements.addClass(class_list);
267 }
264 this._get_selector_element(selector).addClass(class_list);
268 265 },
269 266
270 267 remove_class: function (selector, class_list) {
271 var elements = this._get_selector_element(selector);
272 if (elements.length > 0) {
273 elements.removeClass(class_list);
274 }
268 this._get_selector_element(selector).removeClass(class_list);
275 269 },
276 270
277 271 update: function () {
General Comments 0
You need to be logged in to leave comments. Login now