Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( HTTPNotFound = HTTPErrorWithCode(NewHTTPError("resource does not exist"), 404) ItemNotFound = NewLibraryError("item does not exist in store") TooManyRetries = NewAPIError("too many retries") ResultMustBePointer = NewHTTPError("result must be a pointer") ModalValueNotFound = NewLibraryError("there is no modal component with given custom ID") )
Functions ¶
func IsNotFound ¶
Types ¶
type DiscordError ¶
type DiscordError struct { Message string `json:"message"` Details json.RawMessage `json:"errors"` Code int `json:"code"` }
func (DiscordError) Error ¶
func (v DiscordError) Error() string
type HTTPError ¶
type HTTPError struct { LibraryError Code int }
func HTTPErrorWithCode ¶
func NewHTTPError ¶
type LibraryError ¶
type LibraryError struct {
Message string
}
func NewLibraryError ¶
func NewLibraryError(msg string) *LibraryError
func (LibraryError) Error ¶
func (e LibraryError) Error() string
Click to show internal directories.
Click to hide internal directories.