errors
errors copied to clipboard
How to change format return wrapped error message
https://github.com/pkg/errors/blob/614d223910a179a466c1767a985424175c39b465/errors.go#L244
how can i change format return error message, to this
func (w *withMessage) Error() string { return w.cause.Error()+ " | " + w.msg }
There is no functionality for this provided. You would have to fork the repo.
You could also create a decorator for this and implement it in your own code without needing to manage a fork