Add logging to capture user email upon successful login (#7927)

* Log user email upon successful login

* Add user email to logger context

* Use logging.With Extras for login email
This commit is contained in:
gillespi314
2022-09-27 16:32:46 -03:00
committed by GitHub
parent 474fd8fab8
commit 749ff9ec2b
5 changed files with 59 additions and 4 deletions
-1
View File
@@ -132,7 +132,6 @@ func (l *LoggingContext) Log(ctx context.Context, logger kitlog.Logger) {
}
keyvals = append(keyvals, "user", loggedInUser)
}
requestMethod, ok := ctx.Value(kithttp.ContextKeyRequestMethod).(string)
if !ok {
requestMethod = ""