|
|
@ -6354,9 +6354,9 @@ export class AppMessagesManager { |
|
|
|
const toDispatch: {message: Message.message, changedResults: ReactionCount.reactionCount[]}[] = []; |
|
|
|
const toDispatch: {message: Message.message, changedResults: ReactionCount.reactionCount[]}[] = []; |
|
|
|
|
|
|
|
|
|
|
|
const map = this.getMessagesFromMap(batch); |
|
|
|
const map = this.getMessagesFromMap(batch); |
|
|
|
for(const [message, reactions] of map) { |
|
|
|
for(const [message, previousReactions] of map) { |
|
|
|
const results = reactions?.results ?? []; |
|
|
|
const results = message.reactions?.results ?? []; |
|
|
|
const previousResults = message.reactions?.results ?? []; |
|
|
|
const previousResults = previousReactions?.results ?? []; |
|
|
|
const changedResults = results.filter(reactionCount => { |
|
|
|
const changedResults = results.filter(reactionCount => { |
|
|
|
const previousReactionCount = previousResults.find(_reactionCount => _reactionCount.reaction === reactionCount.reaction); |
|
|
|
const previousReactionCount = previousResults.find(_reactionCount => _reactionCount.reaction === reactionCount.reaction); |
|
|
|
return ( |
|
|
|
return ( |
|
|
|