errors

package
v0.0.0-...-dd2dae2 Latest Latest
Warning

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

Go to latest
Published: Jan 21, 2021 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RestError

type RestError struct {
	Message string `json:"message"`
	Status  int    `json:"status"`
	Error   string `json:"error"`
}

RestError error message struct

func NewBadRequestError

func NewBadRequestError(message string) *RestError

NewBadRequestError creates a new bad request error

func NewInternalServerError

func NewInternalServerError(message string) *RestError

NewInternalServerError creates internal server error

func NewNotFoundError

func NewNotFoundError(message string) *RestError

NewNotFoundError creates a new bad request error

func NewUnauthorizedError

func NewUnauthorizedError(messsage string) *RestError

NewUnauthorizedError create unauthorized error

Jump to

Keyboard shortcuts

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