mirror of
https://github.com/plashchynski/crono.git
synced 2026-04-24 01:38:37 +02:00
Handle situation when Job#next is in the past
This commit is contained in:
@@ -11,7 +11,8 @@ module Crono
|
|||||||
end
|
end
|
||||||
|
|
||||||
def next
|
def next
|
||||||
period.next(since: last_performed_at)
|
next_time = period.next(since: last_performed_at)
|
||||||
|
next_time.past? ? period.next : next_time
|
||||||
end
|
end
|
||||||
|
|
||||||
def description
|
def description
|
||||||
|
|||||||
Reference in New Issue
Block a user