Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-04-15 12:09:46 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2020-04-15 12:09:46 +0300
commit221b529789f4090341a825695aeb49b8df6dd11d (patch)
treec8843e4ca5ef1034752eb68712fcf338b24950db /app/finders
parent00a8c64ffd18e74df4b1cdeda7776b5221fddafe (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/finders')
-rw-r--r--app/finders/users_finder.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/app/finders/users_finder.rb b/app/finders/users_finder.rb
index d5650c6828d..ebb686c2aa7 100644
--- a/app/finders/users_finder.rb
+++ b/app/finders/users_finder.rb
@@ -14,6 +14,7 @@
# active: boolean
# blocked: boolean
# external: boolean
+# without_projects: boolean
#
class UsersFinder
include CreatedAtFilter
@@ -36,6 +37,7 @@ class UsersFinder
users = by_external(users)
users = by_2fa(users)
users = by_created_at(users)
+ users = by_without_projects(users)
users = by_custom_attributes(users)
users
@@ -94,6 +96,12 @@ class UsersFinder
users
end
end
+
+ def by_without_projects(users)
+ return users unless params[:without_projects]
+
+ users.without_projects
+ end
end
UsersFinder.prepend_if_ee('EE::UsersFinder')