TextChannel object
client.on('channelCreate', async (channel) => {
});
This eventhandler, gives a TextChannel object, or VoiceChannel object, the question is, how do i know who created the channel?
8 Replies
- What's your exact discord.js
npm list discord.js
and node node -v
version?
- Not a discord.js issue? Check out #other-js-ts.
- Consider reading #how-to-get-help to improve your question!
- Explain what exactly your issue is.
- Post the full error stack trace, not just the top part!
- Show your code!
- Issue solved? Press the button!audit logs would tell you who created the channel
and how do i use it?
like is it a method, property?
other object
i cant understand
this is logs
Discord.js
Discord.js is a powerful node.js module that allows you to interact with the Discord API very easily. It takes a much more object-oriented approach than most other JS Discord libraries, making your bot's code significantly tidier and easier to comprehend.
use
channel.guild.fetchAuditLogs({ type: AuditLogEvent.ChannelCreate })
and find the channelthank you
that was really helpful