From 906468d15632d108f27ce952906d0ee7c347d79a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A2u=20Cao?= Date: Mon, 5 May 2025 12:46:46 +0400 Subject: [PATCH] Allow to immediately expire auth via job When running the job before its schedule --- app/jobs/remote_storage_expire_authorization_job.rb | 2 -- 1 file changed, 2 deletions(-) diff --git a/app/jobs/remote_storage_expire_authorization_job.rb b/app/jobs/remote_storage_expire_authorization_job.rb index 62c240c..209c463 100644 --- a/app/jobs/remote_storage_expire_authorization_job.rb +++ b/app/jobs/remote_storage_expire_authorization_job.rb @@ -3,8 +3,6 @@ class RemoteStorageExpireAuthorizationJob < ApplicationJob def perform(rs_auth_id) rs_auth = RemoteStorageAuthorization.find rs_auth_id - return unless rs_auth.expire_at.nil? || rs_auth.expire_at <= DateTime.now - rs_auth.destroy! end end