Reputation:
im tryna make it so when the mute command is used it sends the feedback to the logs channel if theres a logs channel heres my code
let logs = Client.channels.find(ch => ch.name = 'logs')
logs.send(embed)
it works but instead of sending to my #logs it sends to my #video-suggestions (i ran the command in #bot-setup)
any help is apreciated :)
Upvotes: 1
Views: 95
Reputation: 3005
You should use
var logs = Client.channels.find(ch => ch.name === "logs");
instead of:
var logs = Client.channels.find(ch => ch.name = "logs");
To compare two values, use ==
or ===
and use =
to assign a value to a variable.
Upvotes: 1