From 6366cf0b181f13eac38f69f1760d6f6f0586a5d1 Mon Sep 17 00:00:00 2001 From: Oleg Lobanov Date: Tue, 22 Feb 2022 10:58:22 +0100 Subject: [PATCH] fix: display user scope for admin users (#1834) --- http/users.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/http/users.go b/http/users.go index 66aab7e2..be7a2d41 100644 --- a/http/users.go +++ b/http/users.go @@ -94,7 +94,7 @@ var userGetHandler = withSelfOrAdmin(func(w http.ResponseWriter, r *http.Request } u.Password = "" - if !u.Perm.Admin { + if !d.user.Perm.Admin { u.Scope = "" } return renderJSON(w, r, u)