mirror of
https://github.com/wekan/wekan.git
synced 2026-03-11 08:02:33 +01:00
Fix: boardAdmin can't edit or delete others comments on cards #4237
This commit is contained in:
parent
fee82f7f7a
commit
ee2fafb6bc
1 changed files with 2 additions and 2 deletions
|
|
@ -75,10 +75,10 @@ CardComments.allow({
|
||||||
return allowIsBoardMember(userId, Boards.findOne(doc.boardId));
|
return allowIsBoardMember(userId, Boards.findOne(doc.boardId));
|
||||||
},
|
},
|
||||||
update(userId, doc) {
|
update(userId, doc) {
|
||||||
return userId === doc.userId;
|
return userId === doc.userId || allowIsBoardAdmin(userId, Boards.findOne(doc.boardId));
|
||||||
},
|
},
|
||||||
remove(userId, doc) {
|
remove(userId, doc) {
|
||||||
return userId === doc.userId;
|
return userId === doc.userId || allowIsBoardAdmin(userId, Boards.findOne(doc.boardId));
|
||||||
},
|
},
|
||||||
fetch: ['userId', 'boardId'],
|
fetch: ['userId', 'boardId'],
|
||||||
});
|
});
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue