errors

package
v1.2.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 4, 2024 License: MIT Imports: 2 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsHTTPError

func IsHTTPError(err error) bool

Types

type HTTPError

type HTTPError struct {
	Code    int    `json:"-"`
	Message string `json:"error"`
}

func BadRequest

func BadRequest(msg string) HTTPError

func InternalServerError

func InternalServerError(msg string) HTTPError

func (HTTPError) Error

func (e HTTPError) Error() string

func (HTTPError) Is added in v1.2.0

func (e HTTPError) Is(err error) bool

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL