Fix emoji unreact

Fixes https://gitlab.com/soapbox-pub/soapbox/-/issues/1616
This commit is contained in:
Alex Gleason 2023-11-14 01:41:45 -06:00
parent 1616cc50e8
commit 9154b63892
No known key found for this signature in database
GPG key ID: 7211D1F99744FBB7

View file

@ -85,6 +85,7 @@ export const simulateUnEmojiReact = (emojiReacts: ImmutableList<EmojiReaction>,
const newCount = (emojiReact.count || 1) - 1;
if (newCount < 1) return emojiReacts.delete(idx);
return emojiReacts.set(idx, emojiReactionSchema.parse({
...emojiReact,
count: (emojiReact.count || 1) - 1,
me: false,
}));