summaryrefslogtreecommitdiff
path: root/lib/api/projects.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/api/projects.rb')
-rw-r--r--lib/api/projects.rb9
1 files changed, 1 insertions, 8 deletions
diff --git a/lib/api/projects.rb b/lib/api/projects.rb
index 7610e3cbacc..267dd2a74d7 100644
--- a/lib/api/projects.rb
+++ b/lib/api/projects.rb
@@ -68,14 +68,7 @@ module API
end
def present_projects(options = {})
- finder_params = {}
- finder_params[:non_public] = true if params[:membership].present?
- finder_params[:starred] = true if params[:starred].present?
- finder_params[:visibility_level] = Gitlab::VisibilityLevel.level_value(params[:visibility]) if params[:visibility]
- finder_params[:archived] = params[:archived]
- finder_params[:search] = params[:search] if params[:search]
-
- projects = ProjectsFinder.new(current_user: current_user, params: finder_params).execute
+ projects = ProjectsFinder.new(current_user: current_user, params: project_finder_params).execute
projects = filter_projects(projects)
projects = projects.with_statistics if params[:statistics]
projects = projects.with_issues_enabled if params[:with_issues_enabled]