diff --git a/src/Client.js b/src/Client.js index 15727c8efb..5c12fd9eb5 100644 --- a/src/Client.js +++ b/src/Client.js @@ -723,10 +723,12 @@ class Client extends EventEmitter { /** @type {GroupNotification} object does not provide enough information about this event, so a @type {Message} object is used. */ const message = new Message(this, msg); - const newId = isParticipant ? msg.recipients[0] : msg.to; + const newId = isParticipant + ? msg.recipients[0] + : msg._data.templateParams[1]; const oldId = isParticipant ? msg.author - : msg.templateParams.find((id) => id !== newId); + : msg._data.templateParams[0]; /** * Emitted when a contact or a group participant changes their phone number.