From 7d42df6737d9622a26008be1ae43fac02c69c2c6 Mon Sep 17 00:00:00 2001 From: loicbersier Date: Fri, 6 Dec 2019 16:54:37 +0100 Subject: [PATCH] Fix join/leave message --- event/listeners/guildMemberAdd.js | 2 +- event/listeners/guildMemberRemove.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/event/listeners/guildMemberAdd.js b/event/listeners/guildMemberAdd.js index 6532ba6a..eda1c12c 100644 --- a/event/listeners/guildMemberAdd.js +++ b/event/listeners/guildMemberAdd.js @@ -15,7 +15,7 @@ class guildMemberAddListener extends Listener { guild.setNickname('fart piss'); } - const join = await joinChannel.findOne({where: {guildID: guild.id}}); + const join = await joinChannel.findOne({where: {guildID: guild.guild.id}}); if (join) { const channel = this.client.channels.get(join.get('channelID')); diff --git a/event/listeners/guildMemberRemove.js b/event/listeners/guildMemberRemove.js index 1d213ab6..f6c54418 100644 --- a/event/listeners/guildMemberRemove.js +++ b/event/listeners/guildMemberRemove.js @@ -11,7 +11,7 @@ class guildMemberRemoveListener extends Listener { } async exec(guild) { - const leave = await leaveChannel.findOne({where: {guildID: guild.id}}); + const leave = await leaveChannel.findOne({where: {guildID: guild.guild.id}}); if (leave) { const channel = this.client.channels.get(leave.get('channelID'));