diff options
Diffstat (limited to 'app/policies/work_items')
-rw-r--r-- | app/policies/work_items/type_policy.rb | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/app/policies/work_items/type_policy.rb b/app/policies/work_items/type_policy.rb new file mode 100644 index 00000000000..c9b3321146a --- /dev/null +++ b/app/policies/work_items/type_policy.rb @@ -0,0 +1,9 @@ +# frozen_string_literal: true + +module WorkItems + class TypePolicy < BasePolicy + condition(:is_default_type) { @subject.default? } + + rule { is_default_type }.enable :read_work_item_type + end +end |