$onlyForChannels
$onlyForChannels will check if the command was executed in one of the listed channels and return a error message if
not.
Usage
$onlyForChannels[...channelIDs;error]Parameters
| Field | Type | Description | Required |
|---|---|---|---|
| …channelIDs | string, number | Channels you want to limit the command to. | true |
| error | string | Error to return when the command was not executed in any of the listed channels. | true |
Example(s)
This will limit the command only to the listed channels:
1client.command({2 name: "onlyForChannels",3 code: `4 Ok.5 $onlyForChannels[channelID;channelID;You can't use that command here!]6 `7});