diff --git a/internal/app/xhttp/middleware.go b/internal/app/xhttp/middleware.go index 456a7cd2..4c6f2262 100644 --- a/internal/app/xhttp/middleware.go +++ b/internal/app/xhttp/middleware.go @@ -111,6 +111,8 @@ func doErr(ctx context.Context, err error) error { // if it's an error from echo // like 404 not found and so on. if echoHTTPErr, ok := err.(*echo.HTTPError); ok { + // required to have a correct status code. + ctx.Error(echoHTTPErr) return echoHTTPErr } // we log the initial error before returning