FEATURE: show Invite button to admin for private topics

This commit is contained in:
Arpit Jalan 2014-07-04 15:09:07 +05:30
parent c2fa382471
commit 4649494e53
1 changed files with 1 additions and 3 deletions

View File

@ -22,7 +22,7 @@ export default Discourse.ContainerView.extend({
if (Discourse.User.current()) {
if (!topic.get('isPrivateMessage')) {
// We hide some controls from private messages
if (this.get('topic.details.can_invite_to') && !this.get('topic.category.read_restricted')) {
if (this.get('topic.details.can_invite_to') && (!this.get('topic.category.read_restricted') || Discourse.User.currentProp('admin'))) {
this.attachViewClass(InviteReplyButton);
}
this.attachViewClass(StarButton);
@ -44,5 +44,3 @@ export default Discourse.ContainerView.extend({
}
}
});