Fixed tag presenter not checking delete privilege
This commit is contained in:
parent
e6ab9ee3b3
commit
be4b742d21
2 changed files with 4 additions and 1 deletions
|
@ -36,6 +36,7 @@ App.Presenters.TagPresenter = function(
|
|||
privileges.canChangeSuggestions = auth.hasPrivilege(auth.privileges.changeTagSuggestions);
|
||||
privileges.canBan = auth.hasPrivilege(auth.privileges.banTags);
|
||||
privileges.canViewHistory = auth.hasPrivilege(auth.privileges.viewHistory);
|
||||
privileges.canDelete = auth.hasPrivilege(auth.privileges.deleteTags);
|
||||
|
||||
promise.wait(
|
||||
util.promiseTemplate('tag'),
|
||||
|
|
|
@ -71,7 +71,9 @@
|
|||
<label class="form-label"></label>
|
||||
<div class="form-input">
|
||||
<button type="submit" name="update">Update</button>
|
||||
<% if (privileges.canDelete) { %>
|
||||
<button type="submit" name="delete">Delete</button>
|
||||
<% } %>
|
||||
</div>
|
||||
</div>
|
||||
<% } %>
|
||||
|
|
Loading…
Reference in a new issue