MM-30865 Invalid Participants handling on post delete in thread (#16353)

Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
Этот коммит содержится в:
Eli Yukelzon
2020-12-01 16:50:39 +02:00
коммит произвёл GitHub
родитель 64499ca767
Коммит 1bd7dc41bd
2 изменённых файлов: 5 добавлений и 5 удалений

Просмотреть файл

@@ -1937,7 +1937,6 @@ func (s *SqlPostStore) cleanupThreads(postId, rootId, userId string, permanent b
}
if thread != nil {
thread.ReplyCount -= 1
thread.Participants = thread.Participants.Remove(userId)
if _, err = s.Thread().Update(thread); err != nil {
return errors.Wrap(err, "failed to update thread")
}