mirror of
https://github.com/wekan/wekan.git
synced 2025-04-24 05:57:13 -04:00
[BUG] Bug when we're removing user from board that generate activity for all the card of the board
This commit is contained in:
parent
c8b7e14835
commit
a370e6aca3
1 changed files with 10 additions and 7 deletions
|
@ -340,13 +340,16 @@ if (Meteor.isServer) {
|
|||
// Say goodbye to the former member
|
||||
if (modifier.$pull && modifier.$pull.members) {
|
||||
memberId = modifier.$pull.members;
|
||||
Activities.insert({
|
||||
userId,
|
||||
memberId,
|
||||
activityType: 'unjoinMember',
|
||||
boardId: doc.boardId,
|
||||
cardId: doc._id,
|
||||
});
|
||||
// Check that the former member is member of the card
|
||||
if (_.contains(doc.members, memberId)) {
|
||||
Activities.insert({
|
||||
userId,
|
||||
memberId,
|
||||
activityType: 'unjoinMember',
|
||||
boardId: doc.boardId,
|
||||
cardId: doc._id,
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue