Fix overriding previous logger in context
This commit is contained in:
@@ -100,7 +100,6 @@ func authenticate(ds model.DataStore) func(next http.Handler) http.Handler {
|
||||
|
||||
ctx = log.NewContext(r.Context(), "username", username)
|
||||
ctx = request.WithUser(ctx, *usr)
|
||||
ctx = request.WithUsername(ctx, usr.UserName)
|
||||
r = r.WithContext(ctx)
|
||||
|
||||
next.ServeHTTP(w, r)
|
||||
|
||||
Reference in New Issue
Block a user