diff options
Diffstat (limited to 'app/models/ci/build.rb')
-rw-r--r-- | app/models/ci/build.rb | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/app/models/ci/build.rb b/app/models/ci/build.rb index 7e7c580a48e..e3f0e07bb8f 100644 --- a/app/models/ci/build.rb +++ b/app/models/ci/build.rb @@ -717,8 +717,8 @@ module Ci end end - def has_expiring_artifacts? - artifacts_expire_at.present? && artifacts_expire_at > Time.now + def has_expiring_archive_artifacts? + has_expiring_artifacts? && artifacts_file&.exists? end def keep_artifacts! @@ -933,6 +933,10 @@ module Ci value.with_indifferent_access end end + + def has_expiring_artifacts? + artifacts_expire_at.present? && artifacts_expire_at > Time.now + end end end |