-
- Downloads
BranchRuleDelete mutation: fix 500 error when rule is missing
Contributes to #508213 **Problem** When the branch rule is missing, the application raises an unhandled exception that leads to InternalServer error. **Solution** Handle the exception in `GitlabSchema` class for non-active record models and return a `nil` for missing objects. Changelog: fixed
parent
3b60c652
No related branches found
No related tags found
Showing
- app/graphql/gitlab_schema.rb 6 additions, 1 deletionapp/graphql/gitlab_schema.rb
- spec/graphql/gitlab_schema_spec.rb 32 additions, 0 deletionsspec/graphql/gitlab_schema_spec.rb
- spec/requests/api/graphql/mutations/branch_rules/destroy_spec.rb 11 additions, 0 deletions...quests/api/graphql/mutations/branch_rules/destroy_spec.rb
- spec/requests/api/graphql/mutations/branch_rules/update_spec.rb 8 additions, 1 deletion...equests/api/graphql/mutations/branch_rules/update_spec.rb
Please register or sign in to comment