bf41063679
Move it to Members::ApproveAccessRequestService. Also, note that there was a double audit event log for access request destruction. Signed-off-by: Rémy Coutable <remy@rymai.me>
14 lines
342 B
Ruby
14 lines
342 B
Ruby
class RemoveExpiredMembersWorker
|
|
include ApplicationWorker
|
|
include CronjobQueue
|
|
|
|
def perform
|
|
Member.expired.find_each do |member|
|
|
begin
|
|
Members::AuthorizedDestroyService.new.execute(member)
|
|
rescue => ex
|
|
logger.error("Expired Member ID=#{member.id} cannot be removed - #{ex}")
|
|
end
|
|
end
|
|
end
|
|
end
|