Class: ProtectedTags::CreateService
- Inherits:
-
BaseService
- Object
- BaseService
- ProtectedTags::CreateService
- Defined in:
- app/services/protected_tags/create_service.rb
Instance Attribute Summary collapse
-
#protected_tag ⇒ Object
readonly
Returns the value of attribute protected_tag.
Attributes inherited from BaseService
#current_user, #params, #project
Instance Method Summary collapse
Methods inherited from BaseService
Methods included from BaseServiceUtility
#deny_visibility_level, #event_service, #log_error, #log_info, #notification_service, #system_hook_service, #todo_service, #visibility_level
Methods included from Gitlab::Allowable
Constructor Details
This class inherits a constructor from BaseService
Instance Attribute Details
#protected_tag ⇒ Object (readonly)
Returns the value of attribute protected_tag.
5 6 7 |
# File 'app/services/protected_tags/create_service.rb', line 5 def protected_tag @protected_tag end |
Instance Method Details
#execute ⇒ Object
7 8 9 10 11 |
# File 'app/services/protected_tags/create_service.rb', line 7 def execute raise Gitlab::Access::AccessDeniedError unless can?(current_user, :admin_project, project) project..create(params) end |