From 48b69c6e2f96ae6487ba178bbb211fc80a7f51c2 Mon Sep 17 00:00:00 2001 From: SpaceEEC Date: Thu, 10 Aug 2017 01:21:34 +0200 Subject: [PATCH] No longer double increment the reaction count when the client reacts (#1755) --- src/structures/Message.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/structures/Message.js b/src/structures/Message.js index 52de85ddd..97584d84d 100644 --- a/src/structures/Message.js +++ b/src/structures/Message.js @@ -548,8 +548,10 @@ class Message { reaction = new MessageReaction(this, emoji, 0, user.id === this.client.user.id); this.reactions.set(emojiID, reaction); } - if (!reaction.users.has(user.id)) reaction.users.set(user.id, user); - reaction.count++; + if (!reaction.users.has(user.id)) { + reaction.users.set(user.id, user); + reaction.count++; + } return reaction; }