-
- Downloads
There was an error fetching the commit references. Please try again later.
Filter params in MR build service
Reusing the existing `IssuableBaseService#filter_params` which uses the policies to determine what params a user can set, and which values it can be set to. This also removed the need for the seperate call to `IssuableBaseService#ensure_milestone_available`. The `Issues::BuildService` does not suffer from this because it limits the params that are assignable to the `title`, `description` and `milestone_id`.
Showing
- app/services/merge_requests/build_service.rb 22 additions, 6 deletionsapp/services/merge_requests/build_service.rb
- changelogs/unreleased/security-bvl-filter-mr-params.yml 5 additions, 0 deletionschangelogs/unreleased/security-bvl-filter-mr-params.yml
- spec/features/merge_request/user_tries_to_access_private_project_info_through_new_mr_spec.rb 20 additions, 1 deletion...ies_to_access_private_project_info_through_new_mr_spec.rb
- spec/services/merge_requests/build_service_spec.rb 36 additions, 1 deletionspec/services/merge_requests/build_service_spec.rb
Please register or sign in to comment