Option to delete a post is shown when privileged with messages_delete
This commit is contained in:
parent
0d714f07ec
commit
6c9768b8e2
|
@ -77,8 +77,7 @@ const ExtraButtons = {
|
||||||
currentUser () { return this.$store.state.users.currentUser },
|
currentUser () { return this.$store.state.users.currentUser },
|
||||||
canDelete () {
|
canDelete () {
|
||||||
if (!this.currentUser) { return }
|
if (!this.currentUser) { return }
|
||||||
const superuser = this.currentUser.rights.moderator || this.currentUser.rights.admin
|
return this.currentUser.privileges.includes('messages_delete') || this.status.user.id === this.currentUser.id
|
||||||
return superuser || this.status.user.id === this.currentUser.id
|
|
||||||
},
|
},
|
||||||
ownStatus () {
|
ownStatus () {
|
||||||
return this.status.user.id === this.currentUser.id
|
return this.status.user.id === this.currentUser.id
|
||||||
|
|
Loading…
Reference in a new issue