From f41786dd271636aa3cb51fdfd8af19a41d68a3ab Mon Sep 17 00:00:00 2001 From: Tue Date: Thu, 6 Oct 2022 09:14:45 +0700 Subject: [PATCH] fix code --- cache/role.go | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/cache/role.go b/cache/role.go index 5274868..20fa546 100644 --- a/cache/role.go +++ b/cache/role.go @@ -42,7 +42,9 @@ func Roles() { } if err := SetKeyValue(role.ID.Hex(), entry, 0); err != nil { logger.Error("usermngmt - CacheRole", logger.LogData{ - "err": err.Error(), + Source: "usermngmt.cache.Roles", + Message: err.Error(), + Data: entry, }) return } @@ -65,7 +67,9 @@ func GetCachedRole(key string) CachedRole { var cachedRole CachedRole if err := json.Unmarshal(value, &cachedRole); err != nil { logger.Error("usermngmt - GetCachedRole - Unmarshal", logger.LogData{ - "err": err.Error(), + Source: "usermngmt.cache.GetCachedRole", + Message: err.Error(), + Data: cachedRole, }) } return cachedRole -- 2.34.1