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

add x/errors.Handler, CreateHandler, NoContentHandler, NoContenetOrNotModifiedHandler and ListHandler ready-to-use handlers for service method calls to Iris Handler

This commit is contained in:
Gerasimos (Makis) Maropoulos
2024-01-09 11:11:53 +02:00
parent 7024f61a62
commit ad75479541
7 changed files with 161 additions and 18 deletions

View File

@@ -139,6 +139,10 @@ func HandleError(ctx *context.Context, err error) bool {
return false
}
if ctx.IsStopped() {
return false
}
for errorCodeName, errorFuncs := range errorFuncCodeMap {
for _, errorFunc := range errorFuncs {
if errToSend := errorFunc(err); errToSend != nil {