Skip to content

Commit

Permalink
Merge pull request #86 from ipfs/fix/85
Browse files Browse the repository at this point in the history
fix: correctly add the skip option to Warningf
  • Loading branch information
Stebalien committed May 13, 2020
2 parents f1add01 + 42cabfc commit cc39b17
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions log.go
@@ -1,6 +1,5 @@
// Package log is the logging library used by IPFS
// (https://github.com/ipfs/go-ipfs). It uses a modified version of
// https://godoc.org/github.com/whyrusleeping/go-logging .
// Package log is the logging library used by IPFS & libp2p
// (https://github.com/ipfs/go-ipfs).
package log

import (
Expand Down Expand Up @@ -41,7 +40,7 @@ func Logger(system string) *ZapEventLogger {
}

logger := getLogger(system)
skipLogger := logger.With(zap.AddCallerSkip(1))
skipLogger := logger.Desugar().WithOptions(zap.AddCallerSkip(1)).Sugar()

return &ZapEventLogger{
system: system,
Expand Down

0 comments on commit cc39b17

Please sign in to comment.