Issue with command info cmd
why does it return "Staff" even if command.perms is "Owner"?
19 Replies
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
Just debug your conditionals.
Log command and config.client before this section.
command log:
config.client log
Perms is an array
You’re testing it against a string
I also tried without an array
gonna try without array again
yeah same result
Is the owner id yours?
yes
So what do you want it to do? You have it set to send owner when author is not owner
it's a command info command, I want users only to see info on commands they can use, so if the command perm is set to "Owner" and the author id is not my id it will send "Owner"
Ok so what’s it doing and what’s the expected result
It sends "Staff" even if the provided command perm is set to "Owner"
Who is testing it
me
So it will never say owner. What is the expected result
wait I just realized it works if I run the command on the channel
config.channels.staffCommands
Yeah that’s because of the ||
but the command perm is owner not staff
&& groups
|| is separate
oh // yeah this fixed it ty