Sha256: 6da0a95b35b16fe9b51fac2bc8f2a448a1cd67ced37d7b2da94a719d245440da
Contents?: true
Size: 439 Bytes
Versions: 8
Compression:
Stored size: 439 Bytes
Contents
# frozen_string_literal: true class LeaseExpiryJob < Hyrax::ApplicationJob def perform records_with_expired_leases.each do |id| work = ActiveFedora::Base.find(id) Hyrax::Actors::LeaseActor.new(work).destroy end end ## # @return [Enumerator<String>] ids for all the objects that have expired active leases def records_with_expired_leases Hyrax::LeaseService.assets_with_expired_leases.map(&:id) end end
Version data entries
8 entries across 8 versions & 1 rubygems