Commit 9a9bb024 authored by kushalpandya's avatar kushalpandya

Optimize jQuery lookup

parent fb78fb73
......@@ -17,8 +17,9 @@ export default class ProtectedTagAccessDropdown {
this.accessLevelsData = accessLevelsData.roles;
this.$dropdown = $dropdown;
this.$wrap = this.$dropdown.closest(`.${this.accessLevel}-container`);
this.usersPath = $('.js-protected-tags-container').data('users-autocomplete');
this.groupsPath = $('.js-protected-tags-container').data('groups-autocomplete');
this.$protectedTagsContainer = $('.js-protected-tags-container');
this.usersPath = this.$protectedTagsContainer.data('users-autocomplete');
this.groupsPath = this.$protectedTagsContainer.data('groups-autocomplete');
this.defaultLabel = this.$dropdown.data('defaultLabel');
this.setSelectedItems([]);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment