From be4b742d212f82047a7cd7050994b2003dfb439e Mon Sep 17 00:00:00 2001 From: Marcin Kurczewski Date: Mon, 10 Nov 2014 11:29:05 +0100 Subject: [PATCH] Fixed tag presenter not checking delete privilege --- public_html/js/Presenters/TagPresenter.js | 1 + public_html/templates/tag.tpl | 4 +++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/public_html/js/Presenters/TagPresenter.js b/public_html/js/Presenters/TagPresenter.js index 68025cba..9c782523 100644 --- a/public_html/js/Presenters/TagPresenter.js +++ b/public_html/js/Presenters/TagPresenter.js @@ -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'), diff --git a/public_html/templates/tag.tpl b/public_html/templates/tag.tpl index 5e0de37e..9c8e6566 100644 --- a/public_html/templates/tag.tpl +++ b/public_html/templates/tag.tpl @@ -71,7 +71,9 @@
- + <% if (privileges.canDelete) { %> + + <% } %>
<% } %>