MCPcopy
hub / github.com/rs/zerolog / Err

Function Err

log/log.go:45–47  ·  view source on GitHub ↗

Err starts a new message with error level with err as a field if not nil or with info level if err is nil. You must call Msg on the returned event in order to send the event.

(err error)

Source from the content-addressed store, hash-verified

43//
44// You must call Msg on the returned event in order to send the event.
45func Err(err error) *zerolog.Event {
46 return Logger.Err(err)
47}
48
49// Trace starts a new message with trace level.
50//

Callers 1

ExampleErrFunction · 0.92

Calls 1

ErrMethod · 0.65

Tested by 1

ExampleErrFunction · 0.74