Clartye
SIASapphire - Imagine a framework
•Created by Clartye on 7/28/2023 in #sapphire-support
TypeError: Cannot read properties of undefined (reading 'channels')
I am trying to automate the welcome messages through the use of a bot and have a functioning listener for the guildMemberAdd event but when trying to get the id of the channel I want to send the message to I get this error. My code is the following
I have at this point quintuple checked that this is the correct channel and correct id for the channel. Does this have something to do with the nature of the client object being passed in. Any help appreciated.
7 replies
SIASapphire - Imagine a framework
•Created by Clartye on 7/28/2023 in #sapphire-support
GuildMemberAdd Event LIstener
I am trying to create an event listener using sapphire ts and discord js. I am trying to find a way to test the event without having to create and ban accounts repeatedly. I tried using the node.js event emitter like so
I tried using Client.emit() as a couple stack overflow but I got an error telling me that there was no method for client named emit. Any help is appreciated.
4 replies