1
0
mirror of https://github.com/kataras/iris.git synced 2026-03-08 01:16:30 +00:00

Happy New Year To Everyone! 🎅

Today is my Birthday too ^_^
This commit is contained in:
Gerasimos (Makis) Maropoulos
2023-12-31 18:56:14 +02:00
parent 50faf05528
commit 56754ff5cc
5 changed files with 178 additions and 3 deletions

View File

@@ -59,7 +59,7 @@ var errorCodeMap = make(map[ErrorCodeName]ErrorCode)
// Example:
//
// var (
// NotFound = errors.E("NOT_FOUND", http.StatusNotFound)
// NotFound = errors.E("NOT_FOUND", http.StatusNotFound)
// )
// ...
// NotFound.Details(ctx, "resource not found", "user with id: %q was not found", userID)
@@ -118,6 +118,7 @@ var (
)
// errorFuncCodeMap is a read-only map of error code names and their error functions.
// See HandleError package-level function.
var errorFuncCodeMap = make(map[ErrorCodeName][]func(error) error)
// HandleError handles an error by sending it to the client