mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-14 10:33:30 +01:00
fix: don't patch set data with undefined (#6694)
This commit is contained in:
@@ -47,13 +47,12 @@ class MessageReaction {
|
||||
}
|
||||
|
||||
_patch(data) {
|
||||
// eslint-disable-next-line eqeqeq
|
||||
if (this.count == undefined) {
|
||||
if ('count' in data) {
|
||||
/**
|
||||
* The number of people that have given the same reaction
|
||||
* @type {?number}
|
||||
*/
|
||||
this.count = data.count;
|
||||
this.count ??= data.count;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user