feat(http): add error logging for API responses (#1819)

* feat(api): add error logging for API responses

* fix: revert import order

* feat(http): log msg

* feat(http): remove extra server logger

---------

Co-authored-by: ze0s <ze0s@riseup.net>
This commit is contained in:
soup 2024-11-16 22:31:48 +01:00 committed by GitHub
parent 74eea79215
commit fc137f2077
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 25 additions and 10 deletions

View file

@ -125,7 +125,7 @@ func (s Server) Handler() http.Handler {
r.Use(c.Handler)
encoder := encoder{}
encoder := newEncoder(s.log)
r.Route("/api", func(r chi.Router) {
r.Route("/auth", newAuthHandler(encoder, s.log, s, s.config.Config, s.cookieStore, s.authService).Routes)