diff --git a/index.js b/index.js index 2d75fc9..d16cba3 100644 --- a/index.js +++ b/index.js @@ -49,7 +49,7 @@ client.on('channelCreate', channel => { const channelName = channel.name; const channelID = channel.id; let channelCategory; - if (channel.parent.name) { + if (channel.parent) { channelCategory = channel.parent.name; } else { channelCategory = "None";