diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-05-25 18:10:42 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-05-25 18:10:42 +0000 |
commit | a880341a7b3a164ba381620852cc3ea0777f67ad (patch) | |
tree | de7f7a09aee296eef7924cad7eb7ec2e9ea29ce0 /app/models/environment_status.rb | |
parent | a8c1bc6f757ecacbc3481e52a3f4cefb6c6db5fd (diff) | |
download | gitlab-ce-a880341a7b3a164ba381620852cc3ea0777f67ad.tar.gz |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/models/environment_status.rb')
-rw-r--r-- | app/models/environment_status.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/environment_status.rb b/app/models/environment_status.rb index 55ea4e2fe18..07c0983f239 100644 --- a/app/models/environment_status.rb +++ b/app/models/environment_status.rb @@ -100,7 +100,7 @@ class EnvironmentStatus def self.build_environments_status(mr, user, pipeline) return [] unless pipeline - pipeline.environments.includes(:project).available.map do |environment| + pipeline.environments_in_self_and_descendants.includes(:project).available.map do |environment| next unless Ability.allowed?(user, :read_environment, environment) EnvironmentStatus.new(pipeline.project, environment, mr, pipeline.sha) |