mirror of
https://0xacab.org/sutty/sutty
synced 2024-11-16 15:31:43 +00:00
fixup! feat: almacenar y renovar tokens de distributed press
This commit is contained in:
parent
67c0b29029
commit
cbf7b58927
1 changed files with 2 additions and 2 deletions
|
@ -18,9 +18,9 @@ class DistributedPressPublisher < ApplicationRecord
|
|||
before_save :update_expires_at_from_token!, :update_token_from_client!
|
||||
|
||||
# Devuelve todos los tokens que vencen en una hora
|
||||
scope :with_about_to_expire_tokens, -> do
|
||||
scope :with_about_to_expire_tokens, lambda {
|
||||
where('expires_at > ? and expires_at < ?', Time.now, Time.now + 1.hour)
|
||||
end
|
||||
}
|
||||
|
||||
# Al cambiar el token genera un cliente nuevo
|
||||
#
|
||||
|
|
Loading…
Reference in a new issue