Skip to content
This repository was archived by the owner on May 16, 2019. It is now read-only.

Commit 274b1ea

Browse files
committed
Moved more logic to template.
1 parent 3045beb commit 274b1ea

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

js/templates/userPage.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ <h1 class="page-userNameLarge floatLeft fancy-heading fontSize20 colorWhiteForce
137137
</span>
138138
</a>
139139
</div>
140-
<% if(ob.page.profile.moderator) { %>
140+
<% if(ob.page.profile.moderator && ob.user.vendor) { %>
141141
<div class="ctrlGroup hide js-notOwnPageButtons js-userPageControls">
142142
<a class="btn btn-txt custCol-primary hide js-addmoderator">
143143
<span class="ion-person-add fontSize11 marginRight2 textOpacity1"></span>

js/views/userPageVw.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -708,9 +708,7 @@ module.exports = baseVw.extend({
708708
},
709709

710710
getIsModerator: function () {
711-
if(this.options.ownPage == false && this.model.get('user').vendor) {
712-
this.toggleModeratorButtons(Boolean(__.findWhere(this.model.get('user').moderators, {guid: this.pageID})));
713-
}
711+
this.toggleModeratorButtons(Boolean(__.findWhere(this.model.get('user').moderators, {guid: this.pageID})));
714712
},
715713

716714
renderItems: function (model, skipNSFWmodal) {

0 commit comments

Comments
 (0)