Question about "runIn" preconditions

Hello! According to the docs regarding setting the channel types a command can run in. In theory setting the command's runIn to
// ...
runIn: [CommandOptionsRunTypeEnum.GuildText, CommandOptionsRunTypeEnum.GuildVoice]
// ...
// ...
runIn: [CommandOptionsRunTypeEnum.GuildText, CommandOptionsRunTypeEnum.GuildVoice]
// ...
Should make the command run in both text channels and voice based text channels. However, setting it like this, doesn't allow me to run them to both channel types. What I can do was to only set one channel type in runIn and it'd work for that particular channel type only. How can I make it so that I can allow the command to run in both channel types?
5 Replies
Favna
Favna16mo ago
GitHub
refactor(preconditions): add RunIn, deprecate everything else (#6...
* refactor(preconditions): add RunIn, deprecate everything else * fix: refactor DMOnly precondition * fix: correct string
Favna
Favna16mo ago
I'll release tonight
Dolliwyx
DolliwyxOP16mo ago
I see, so if I understood this correctly, the correct way to do the core preconditions now are through runIn, and not the preconditions option anymore? amazing POGGERS
Favna
Favna16mo ago
yes
Dolliwyx
DolliwyxOP16mo ago
I see, thank you! bloblove
Want results from more Discord servers?
Add your server