Fixed unwrap method.

This commit is contained in:
jdl 2023-12-05 11:16:35 +01:00
parent 875957f662
commit 54c9e89c3e

View File

@ -50,10 +50,7 @@ func (e *Error) WithErr(err error) *Error {
} }
func (e *Error) Unwrap() error { func (e *Error) Unwrap() error {
if e.err != nil {
return e.err return e.err
}
return e
} }
func (e *Error) WithMsg(msg string, args ...any) *Error { func (e *Error) WithMsg(msg string, args ...any) *Error {