// One error class for the package. exitCode follows docs/TOOLS.md: 1 operation // failed, 2 invalid data or configuration, 3 refused by a brake (STOP or a // held binding; a supervisor must not retry), 4 usage. export class DiscordError extends Error { constructor(message, exitCode = 2, details = undefined) { super(message); this.name = "DiscordError"; this.exitCode = exitCode; if (details !== undefined) this.details = details; } }