2
0
Fork 0
mirror of https://github.com/discourse/discourse.git synced 2025-09-05 08:59:27 +08:00

DEV: allow queue_jobs = false in dev

your mileage may vary
This commit is contained in:
Sam 2017-10-31 13:48:47 +11:00
parent d15068da70
commit 7c5a71e929

View file

@ -200,8 +200,14 @@ module Jobs
# Otherwise execute the job right away
opts.delete(:delay_for)
opts[:sync_exec] = true
if Rails.env == "development"
Scheduler::Defer.later("job") do
klass.new.perform(opts)
end
else
klass.new.perform(opts)
end
end
end