summaryrefslogtreecommitdiff
path: root/lib/api/users.rb
diff options
context:
space:
mode:
authorMike Greiling <mike@pixelcog.com>2017-09-18 13:05:34 -0500
committerMike Greiling <mike@pixelcog.com>2017-09-18 13:05:34 -0500
commit27a28d9970c28142aa4482b6f474b79ccaec2bec (patch)
tree715cd65e1e7847bf91d525c800435de96f255ef6 /lib/api/users.rb
parent4c0beb6c024b25ff24c7c2ea966bacab0ee860d5 (diff)
parent9b13753302df7a3e8ef86c6af3f84066bde31a21 (diff)
downloadgitlab-ce-27a28d9970c28142aa4482b6f474b79ccaec2bec.tar.gz
Merge branch 'master' into sh-headless-chrome-support
* master: (97 commits) Eliminate N+1 queries in loading discussions.json endpoint Clean up read_registry scope changes Add missing import statements Improve “New project“ page description Fix notification message when admin label was modified Remove gaps under nav on build page Replace the 'project/snippets.feature' spinach test with an rspec analog Use correct group members path for members flyout link Fix docs for lightweight tag creation via API Replace the 'project/commits/revert.feature' spinach test with an rspec analog Merge branch 'rs-incoming-email-domain-docs' into 'security-10-0' Replace the 'project/archived.feature' spinach test with an rspec analog Fix broken link in docs/api/wiki.md Fixed the new sidebars width when browser has scrollbars Improve 'spec/features/profiles/*' specs Replace the 'search.feature' spinach test with an rspec analog dedupe yarn packages add dependency approvals (all MIT license) update build image to latest with node 8.x, yarn 1.0.2, and chrome 61 Ensure we use `Entities::User` for non-admin `users/:id` API requests ...
Diffstat (limited to 'lib/api/users.rb')
-rw-r--r--lib/api/users.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/api/users.rb b/lib/api/users.rb
index 1825c90a23b..bdebda58d3f 100644
--- a/lib/api/users.rb
+++ b/lib/api/users.rb
@@ -88,7 +88,7 @@ module API
user = User.find_by(id: params[:id])
not_found!('User') unless user && can?(current_user, :read_user, user)
- opts = current_user&.admin? ? { with: Entities::UserWithAdmin } : {}
+ opts = current_user&.admin? ? { with: Entities::UserWithAdmin } : { with: Entities::User }
present user, opts
end