From 10b6135bde89cf8aa4a939b7a4b6fe992fa4907b Mon Sep 17 00:00:00 2001 From: Benedikt Kulmann Date: Fri, 28 Aug 2020 11:49:15 +0200 Subject: [PATCH] Fix variable naming --- middleware/roles.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/middleware/roles.go b/middleware/roles.go index 532c1f28f9..cb64a0ca64 100644 --- a/middleware/roles.go +++ b/middleware/roles.go @@ -54,11 +54,11 @@ func Roles(log log.Logger, rs settings.RoleService, cache *roles.Cache) func(nex // ReadRoleIDsFromContext extracts roleIDs from the metadata context and returns them as []string func ReadRoleIDsFromContext(ctx context.Context) (roleIDs []string, ok bool) { - roleIDsJson, ok := metadata.Get(ctx, RoleIDs) + roleIDsJSON, ok := metadata.Get(ctx, RoleIDs) if !ok { return nil, false } - err := json.Unmarshal([]byte(roleIDsJson), &roleIDs) + err := json.Unmarshal([]byte(roleIDsJSON), &roleIDs) if err != nil { return nil, false }