utils

package
v0.0.4 Latest Latest
Warning

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

Go to latest
Published: Jun 23, 2023 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewError

func NewError(ctx *gin.Context, status int, err error)

NewError creates an error in the gin context.

func ParseRoundAndColumn

func ParseRoundAndColumn(clueString string) (int64, int64)

ParseRoundAndColumn parses a clue string and returns the round and column.

Types

type HTTPError

type HTTPError struct {
	Code    int    `json:"code" example:"400"`
	Message string `json:"message" example:"status bad request"`
}

HTTPError is the error response for the API.

Jump to

Keyboard shortcuts

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