mirror of
https://git.mirrors.martin98.com/https://github.com/SigNoz/signoz
synced 2025-08-14 03:55:57 +08:00
chore: add user email to log_comment (#6461)
This commit is contained in:
parent
cd1ec561b1
commit
493ae4fd07
@ -384,6 +384,11 @@ func LogCommentEnricher(next http.Handler) http.Handler {
|
||||
client = "api"
|
||||
}
|
||||
|
||||
email, err := auth.GetEmailFromJwt(r.Context())
|
||||
if err != nil {
|
||||
zap.S().Errorf("error while getting email from jwt: %v", err)
|
||||
}
|
||||
|
||||
kvs := map[string]string{
|
||||
"path": path,
|
||||
"dashboardID": dashboardID,
|
||||
@ -392,6 +397,7 @@ func LogCommentEnricher(next http.Handler) http.Handler {
|
||||
"client": client,
|
||||
"viewName": viewName,
|
||||
"servicesTab": tab,
|
||||
"email": email,
|
||||
}
|
||||
|
||||
r = r.WithContext(context.WithValue(r.Context(), common.LogCommentKey, kvs))
|
||||
|
Loading…
x
Reference in New Issue
Block a user