Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
admpub committed Jun 27, 2024
1 parent 9112102 commit 96ae254
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions middleware/log.go
Original file line number Diff line number Diff line change
Expand Up @@ -116,13 +116,11 @@ func LogWithConfig(config LogConfig) echo.MiddlewareFunc {
}
info := AcquireVisitorInfo()
info.Time = time.Now()
if err := h.Handle(c); err != nil {
c.Error(err)
}
err := h.Handle(c)
info.SetFromContext(c)
config.Execute(info)
ReleaseVisitorInfo(info)
return nil
return err
})
}
}

0 comments on commit 96ae254

Please sign in to comment.