diff --git a/exerr/builder.go b/exerr/builder.go index 838715e..8cf566f 100644 --- a/exerr/builder.go +++ b/exerr/builder.go @@ -493,11 +493,12 @@ func (b *Builder) Format(level LogPrintLevel) string { // If the error is SevErr we also send it to the error-service func (b *Builder) Fatal(ctxs ...context.Context) { + b.errorData.Severity = SevFatal + for _, dctx := range ctxs { b.CtxData(MethodFatal, dctx) } - b.errorData.Severity = SevFatal b.errorData.Log(stackSkipLogger.WithLevel(zerolog.FatalLevel)) b.errorData.CallListener(MethodFatal) diff --git a/exerr/constructor.go b/exerr/constructor.go index c80715d..08b80b9 100644 --- a/exerr/constructor.go +++ b/exerr/constructor.go @@ -56,7 +56,7 @@ func wrapExErr(e *ExErr, msg string, cat ErrorCategory, stacktraceskip int) *ExE UniqueID: newID(), Category: cat, Type: TypeWrap, - Severity: SevErr, + Severity: e.Severity, Timestamp: time.Now(), StatusCode: e.StatusCode, Message: msg, diff --git a/goextVersion.go b/goextVersion.go index 0cbac08..bbbcbf3 100644 --- a/goextVersion.go +++ b/goextVersion.go @@ -1,5 +1,5 @@ package goext -const GoextVersion = "0.0.465" +const GoextVersion = "0.0.466" -const GoextVersionTimestamp = "2024-06-03T09:39:57+0200" +const GoextVersionTimestamp = "2024-06-03T13:48:30+0200"