Add auth.user.name to logging context
This commit is contained in:
parent
e5eddbc762
commit
9898552656
2 changed files with 4 additions and 2 deletions
|
@ -66,7 +66,7 @@ func (ac *accessController) Authorized(ctx context.Context, accessRecords ...aut
|
|||
return nil, &challenge
|
||||
}
|
||||
|
||||
return context.WithValue(ctx, "auth.user", auth.UserInfo{Name: "silly"}), nil
|
||||
return auth.WithUser(ctx, auth.UserInfo{Name: "silly"}), nil
|
||||
}
|
||||
|
||||
type challenge struct {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue