mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-09 16:13:31 +01:00
fix: don't patch set data with undefined (#6694)
This commit is contained in:
@@ -51,11 +51,13 @@ class ThreadChannel extends Channel {
|
||||
_patch(data, partial = false) {
|
||||
super._patch(data);
|
||||
|
||||
/**
|
||||
* The name of the thread
|
||||
* @type {string}
|
||||
*/
|
||||
this.name = data.name;
|
||||
if ('name' in data) {
|
||||
/**
|
||||
* The name of the thread
|
||||
* @type {string}
|
||||
*/
|
||||
this.name = data.name;
|
||||
}
|
||||
|
||||
if ('guild_id' in data) {
|
||||
this.guildId = data.guild_id;
|
||||
|
||||
Reference in New Issue
Block a user