common

package module
v0.0.0-...-ece3cc1 Latest Latest
Warning

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

Go to latest
Published: May 23, 2024 License: GPL-3.0 Imports: 4 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrEmptyOrderProducts          = errors.New("required at least one product")
	ErrInvalidOrderProductQuantity = errors.New("invalid order product quantity must greater than zero")
)

Functions

func EnvString

func EnvString(key, fallback string) string

func ReadJSON

func ReadJSON(r *http.Request, data any) error

func WriteError

func WriteError(w http.ResponseWriter, status int, message string)

func WriteJSON

func WriteJSON(w http.ResponseWriter, status int, data any)

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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