Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FmtErrDefault ¶
FmtErrDefault is the default format function to convert failing Filter(s) into an error string
Types ¶
type Error ¶
type Error struct {
// contains filtered or unexported fields
}
Error is an error that has a failing Filter attached
type Filter ¶
type Filter int
Filter represents a condition that prevents a `Command` or `Event` from firing. Only use the given const filters which range from 2^0 to 2^4.
const ( // MsgFromSelf ignores handling of messages from the bot itself MsgFromSelf Filter = 1 << iota // MsgFromBot ignores handling of messages from all bots. Encapsulates MsgFromSelf. MsgFromBot // MsgFromWebhook ignores handling of messages from webhooks MsgFromWebhook // MsgNoContent ignores handling if messages without a text body. (e.g. messages with only attachments) MsgNoContent // MsgIsPrivate ignores handling if the message is sent in a DM MsgIsPrivate // MsgIsGuildText ignores handling if the message is sent from a guild text channel MsgIsGuildText )
Click to show internal directories.
Click to hide internal directories.