Skip to content

More info

Compare
Choose a tag to compare
@Pr0Ger Pr0Ger released this 12 Dec 21:21
· 23 commits to master since this release

Versions:

  • Bump go.uber.org/zap to 1.24.0
  • Bump github.com/getsentry/sentry-go to 0.16.0

Changes:

  • Add ExtraFields middleware
    It allows you to inject some fields aftermath. For example:
router.Use(logger.RequestLogger(log))   // Injects logger into request context
router.Use(AuthMiddleware)              // Check auth and inject user info into context or throw 401
router.Use(logger.WithExtraFields(...)) // Grab user info from previous middleware and add it to logger