From d6ff8dc9b67b8bc80e6f5f4f1bc35c14a284ebd2 Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Wed, 10 Jan 2018 11:34:37 +0100 Subject: introduce datasrc2src(selector) js function --- view/js/acl.js | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'view/js/acl.js') diff --git a/view/js/acl.js b/view/js/acl.js index 6042b43ca..c8f7c7180 100644 --- a/view/js/acl.js +++ b/view/js/acl.js @@ -173,11 +173,7 @@ ACL.prototype.on_custom = function(event) { that.deny_cid = []; that.deny_gid = []; - $("#acl-list-content .acl-list-item img[data-src]").each(function(i, el) { - //Replace data-src attribute with src attribute for every image - $(el).attr('src', $(el).data("src")); - $(el).removeAttr("data-src"); - }); + datasrc2src('#acl-list-content .acl-list-item img[data-src]'); that.update_view('custom'); that.on_submit(); -- cgit v1.2.3