utils

package
v1.0.7 Latest Latest
Warning

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

Go to latest
Published: Jan 16, 2025 License: BSD-3-Clause Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrAuthKey                  = errors.New("failed with auth key from request events")
	ErrCreateTable              = errors.New("failed with table creation")
	ErrConnectDB                = errors.New("failed to initialize database")
	ErrReadRequestDataUnmarshal = errors.New("bad request data from plugin")
)

Functions

func MakeHiddenConfigFolder

func MakeHiddenConfigFolder(path string) error

func MigrateToNewConfigPath

func MigrateToNewConfigPath(newConfigPath, oldConfigPath string) error

func WriteErrorResponse

func WriteErrorResponse(err error)

func WriteResponse

func WriteResponse(response ResponseForPlugin)

func WriteSuccessResponse

func WriteSuccessResponse()

Types

type ResponseForPlugin

type ResponseForPlugin struct {
	Status bool   `json:"status"`
	Error  string `json:"error"`
}

Jump to

Keyboard shortcuts

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