|
@@ -60,14 +60,14 @@ type withMessage struct {
|
|
|
msg string
|
|
|
}
|
|
|
|
|
|
-func (w *withMessage) Error() string { return w.msg + ": " + w.cause.Error() }
|
|
|
+func (w *withMessage) Error() string { return w.msg }
|
|
|
func (w *withMessage) Cause() error { return w.cause }
|
|
|
func (w *withMessage) Unwrap() error { return w.cause }
|
|
|
func (w *withMessage) Format(s fmt.State, verb rune) {
|
|
|
switch verb {
|
|
|
case 'v':
|
|
|
if s.Flag('+') {
|
|
|
- io.WriteString(s, w.msg+": ")
|
|
|
+ io.WriteString(s, w.msg+"\n")
|
|
|
if w.Cause() != nil {
|
|
|
fmt.Fprintf(s, "%+v", w.Cause())
|
|
|
}
|