From: Marcin Koziej Date: Wed, 13 Feb 2013 14:18:34 +0000 (+0100) Subject: data() considered harmful X-Git-Url: https://git.mdrn.pl/edumed.git/commitdiff_plain/5c7bc1d4380a5c51f13aa274cbea211e4a444a9e?ds=sidebyside data() considered harmful --- diff --git a/catalogue/static/catalogue/js/edumed.js b/catalogue/static/catalogue/js/edumed.js index 2c5e308..17d485f 100644 --- a/catalogue/static/catalogue/js/edumed.js +++ b/catalogue/static/catalogue/js/edumed.js @@ -493,7 +493,7 @@ _ref = $(".question-piece", this.element); for (_i = 0, _len = _ref.length; _i < _len; _i++) { qp = _ref[_i]; - if ($(qp).data('solution').split(/[ ,]+/).length > 1) { + if ($(qp).attr('data-solution').split(/[ ,]+/).length > 1) { return true; } }