utils

package
v0.0.0-...-3a27eef Latest Latest
Warning

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

Go to latest
Published: Jun 24, 2020 License: GPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RespondError

func RespondError(w http.ResponseWriter, code int, message string)

RespondError makes error json format

func ResponseJSON

func ResponseJSON(w http.ResponseWriter, status int, payload interface{})

ResponseJSON makes json response

Types

type Empty

type Empty struct{}

type Error

type Error struct {
	Message string
}

Struct of error response TODO: add unique code

Jump to

Keyboard shortcuts

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