diff options
author | Robert Schilling <rschilling@student.tugraz.at> | 2018-02-20 18:20:14 +0100 |
---|---|---|
committer | Robert Schilling <rschilling@student.tugraz.at> | 2018-02-20 20:05:12 +0100 |
commit | e8fc5dd89d503f83e4ce707c3051008c54720027 (patch) | |
tree | 0474a772713bb5d721c02f15f8675adb57a69c25 /lib/api/helpers.rb | |
parent | 81add16e67aabaf907365c8061019b371d20ec3b (diff) | |
download | gitlab-ce-api-fix-archived.tar.gz |
API: Fix archived parameter for projects APIapi-fix-archived
Diffstat (limited to 'lib/api/helpers.rb')
-rw-r--r-- | lib/api/helpers.rb | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/lib/api/helpers.rb b/lib/api/helpers.rb index 6134ad2bfc7..643d9a05009 100644 --- a/lib/api/helpers.rb +++ b/lib/api/helpers.rb @@ -379,7 +379,16 @@ module API 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] + + unless params[:archived].nil? + finder_params[:archived] = + if params[:archived] + 'only' + else + false + end + end + finder_params[:search] = params[:search] if params[:search] finder_params[:user] = params.delete(:user) if params[:user] finder_params[:custom_attributes] = params[:custom_attributes] if params[:custom_attributes] |