Use GroupHook policies in controller
The policies got introduced in: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/88245 but they were not used in controllers to check access. To avoid confusion, this makes use of the policies.
显示
- ee/app/controllers/groups/hooks_controller.rb 6 个添加, 1 个删除ee/app/controllers/groups/hooks_controller.rb
- ee/app/policies/group_hook_policy.rb 1 个添加, 2 个删除ee/app/policies/group_hook_policy.rb
- ee/spec/controllers/groups/hooks_controller_spec.rb 19 个添加, 2 个删除ee/spec/controllers/groups/hooks_controller_spec.rb
- ee/spec/policies/group_hook_policy_spec.rb 4 个添加, 4 个删除ee/spec/policies/group_hook_policy_spec.rb
想要评论请 注册 或 登录