Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2022-12-14 18:08:04 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2022-12-14 18:08:04 +0300
commit8c4225a66b12683bcf1bba9bb9328fcf65395b6d (patch)
treed3b583abd26fcbbcbf0db828aee2b940414e1649 /app/policies/issuable_policy.rb
parent075c890053f626018ba680e4da21a93743acb244 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/policies/issuable_policy.rb')
-rw-r--r--app/policies/issuable_policy.rb3
1 files changed, 3 insertions, 0 deletions
diff --git a/app/policies/issuable_policy.rb b/app/policies/issuable_policy.rb
index aa07bb7dc5f..779384ee3fe 100644
--- a/app/policies/issuable_policy.rb
+++ b/app/policies/issuable_policy.rb
@@ -16,6 +16,9 @@ class IssuablePolicy < BasePolicy
condition(:is_incident) { @subject.incident? }
+ desc "Issuable is hidden"
+ condition(:hidden, scope: :subject) { @subject.hidden? }
+
rule { can?(:guest_access) & assignee_or_author & ~is_incident }.policy do
enable :read_issue
enable :update_issue