Skip to content

Commit

Permalink
fix(Webhook): Resolve source guild only if cached (#6834)
Browse files Browse the repository at this point in the history
  • Loading branch information
Jiralite committed Oct 16, 2021
1 parent ef01b84 commit d193d04
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/structures/Webhook.js
Expand Up @@ -90,7 +90,7 @@ class Webhook {
* The source guild of the webhook
* @type {?(Guild|APIGuild)}
*/
this.sourceGuild = this.client.guilds?._add(data.source_guild, false) ?? data.source_guild;
this.sourceGuild = this.client.guilds?.resolve(data.source_guild.id) ?? data.source_guild;
} else {
this.sourceGuild ??= null;
}
Expand Down

0 comments on commit d193d04

Please sign in to comment.