This commit is contained in:
Dragon Fire
2020-12-01 20:15:20 -05:00
parent b8e3fc819a
commit 519a43af1d
+3 -3
View File
@@ -48,10 +48,10 @@ module.exports = class PhoneCommand extends Command {
&& channel.topic.includes('<xiao:phone>')
&& !channel.topic.includes('<xiao:phone:no-random>')
&& !channel.topic.includes(`<xiao:phone:block:${msg.channel.id}>`)
&& !channel.topic.includes(`<xiao:phone:block:${msg.guild.id}>`)
&& (msg.guild && !channel.topic.includes(`<xiao:phone:block:${msg.guild.id}>`))
&& (msg.channel.topic && !msg.channel.topic.includes(`<xiao:phone:block:${channel.id}>`))
&& (msg.channel.topic && !msg.channel.topic.includes(`<xiao:phone:block:${channel.guild.id}>`))
&& !msg.guild.channels.cache.has(channel.id)
&& (msg.guild && !msg.guild.channels.cache.has(channel.id))
&& (channelID ? true : !this.client.inPhoneCall(channel)));
if (!channels.size) return msg.reply('No channels currently allow phone calls...');
let channel;
@@ -66,7 +66,7 @@ module.exports = class PhoneCommand extends Command {
if (channel.topic.includes(`<xiao:phone:block:${msg.channel.id}>`)) {
return msg.reply('That channel has blocked this channel from calling them.');
}
if (channel.topic.includes(`<xiao:phone:block:${msg.guild.id}>`)) {
if (msg.guild && channel.topic.includes(`<xiao:phone:block:${msg.guild.id}>`)) {
return msg.reply('That channel has blocked this server from calling them.');
}
} else {