diff options
author | Grzegorz Bizon <grzesiek.bizon@gmail.com> | 2016-11-16 14:39:06 +0300 |
---|---|---|
committer | Grzegorz Bizon <grzesiek.bizon@gmail.com> | 2016-11-16 14:39:06 +0300 |
commit | 5d5b80a608d8d89525e5e903ea47c6b66e13ed23 (patch) | |
tree | 52678f22b6a729892431f29d06b704560b2f73e7 /app/services | |
parent | 3cf516cd201e0802d284d664e50dfde409047ca4 (diff) |
Remove unnecessary check from environments service
Diffstat (limited to 'app/services')
-rw-r--r-- | app/services/ci/stop_environments_service.rb | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/app/services/ci/stop_environments_service.rb b/app/services/ci/stop_environments_service.rb index 0ffe73611c4..cf590459cb2 100644 --- a/app/services/ci/stop_environments_service.rb +++ b/app/services/ci/stop_environments_service.rb @@ -6,7 +6,6 @@ module Ci @ref = branch_name return unless has_ref? - return unless has_environments? environments.each do |environment| next unless environment.stoppable? @@ -22,10 +21,6 @@ module Ci @ref.present? end - def has_environments? - environments.any? - end - def environments @environments ||= project .environments_recently_updated_on_branch(@ref) |