Skip to content
GitHub

PresentedError

interface in meocord/interface Since 4.1.0

interface PresentedError

An error a presenter styles: the words a filter chose, and the error itself.

Members

message

message: string

What the user is told.

error

error: unknown

The error being answered, so a presenter can style it by kind.

tone

tone: 'warning' | 'danger'

Which theme colour suits the error: 'warning' for the user's own outcome, such as a cooldown, a refused guard or a UserError, and 'danger' for a fault in the bot. Read context.theme.colors[tone].