class Rufus::Scheduler::JobQueue
def job_to_trigger(now)
Returns the next job to trigger. Returns nil if none eligible.
def job_to_trigger(now) @mutex.synchronize do if @jobs.size > 0 && now.to_f >= @jobs.first.at @jobs.shift else nil end end end
def job_to_trigger(now) @mutex.synchronize do if @jobs.size > 0 && now.to_f >= @jobs.first.at @jobs.shift else nil end end end