$customCommandExists
Returns `true` if the custom command exists in the database for the guild. Otherwise, the function will return `false`.

FUNCTION USAGE

  • $customCommandExists[name]
  • $customCommandExists[name;guildID]

Properties:

name - The command to check for existence. guildID - The guild ID of the guild where the custom command belongs to. Defaults to the current guild if left blank.

Example 1:

bot.Command({
name: "exists",
code: `
$onlyIf[$customCommandExists[$message[1]]==true;The custom command does not exist for this guild]
`
})

Example 2:

bot.Command({
name: "exists",
code: `
$onlyIf[$customCommandExists[$message[1];$message[2]]==true;The custom command does not exist for the guild: $guildName[$message[2]]
`
})
Copy link