DEV: Remove deprecated queue_jobs site setting (#24127)

Using SiteSetting.queue_jobs= to configure job asynchronicity was deprecated here four years ago and marked for removal in version 2.9.0. This PR removes the fallback method we kept since then. The method was there because it was still being used in a bunch of plugin tests (now fixed.)
This commit is contained in:
Ted Johansson 2023-10-27 11:05:02 +08:00 committed by GitHub
parent 3ad8e1fbde
commit d0915027a8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 1 additions and 9 deletions

View File

@ -106,14 +106,6 @@ class SiteSetting < ActiveRecord::Base
ListController.best_period_with_topics_for(duration)
end
def self.queue_jobs=(val)
Discourse.deprecate(
"queue_jobs is deprecated. Please use Jobs.run_immediately! instead",
drop_from: "2.9.0",
)
val ? Jobs.run_later! : Jobs.run_immediately!
end
def self.email_polling_enabled?
SiteSetting.manual_polling_enabled? || SiteSetting.pop3_polling_enabled? ||
DiscoursePluginRegistry.mail_pollers.any?(&:enabled?)

View File

@ -3,7 +3,7 @@
require "rails_helper"
describe PrettyText do
before { SiteSetting.queue_jobs = false }
before { Jobs.run_immediately! }
it "can be disabled" do
SiteSetting.enable_markdown_footnotes = false