2019-05-02 18:17:27 -04:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2017-04-05 22:52:13 -04:00
|
|
|
module Jobs
|
2019-10-02 00:01:53 -04:00
|
|
|
class RemoveOldAutoCloseJobs < ::Jobs::Onceoff
|
2017-04-05 22:52:13 -04:00
|
|
|
def execute_onceoff(args)
|
2017-04-06 01:45:59 -04:00
|
|
|
Jobs.cancel_scheduled_job(:close_topic)
|
2017-04-05 22:52:13 -04:00
|
|
|
|
|
|
|
# No need to enqueue new jobs since we have a scheduled job that will
|
|
|
|
# automatically enqueue the new jobs.
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|