Revert the wrapping of write errors
All errors generated by Go libraries on stderr won't be json encoded anyway, so it does not make sense to have such a treatment for this one.
This commit is contained in:
parent
3f112dae87
commit
8e30c71369
3
event.go
3
event.go
|
@ -137,8 +137,7 @@ func (e *Event) msg(msg string) {
|
||||||
defer e.done(msg)
|
defer e.done(msg)
|
||||||
}
|
}
|
||||||
if err := e.write(); err != nil {
|
if err := e.write(); err != nil {
|
||||||
fmt.Fprintf(os.Stderr,
|
fmt.Fprintf(os.Stderr, "zerolog: could not write event: %v", err)
|
||||||
`{"%s": "zerolog: could not write event: %v"}\n`, MessageFieldName, err)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue