Fix onceoff job to only run when slack is installed
This commit is contained in:
parent
1e52671c03
commit
92e22d65da
|
@ -4,6 +4,7 @@ module Jobs
|
|||
# Check if slack plugin is installed by testing if the sitesetting exists
|
||||
slack_installed = defined? DiscourseSlack
|
||||
|
||||
if slack_installed
|
||||
already_setup_rules = DiscourseChat::Channel.with_provider('slack').exists?
|
||||
|
||||
already_setup_sitesettings =
|
||||
|
@ -16,6 +17,7 @@ module Jobs
|
|||
migrate_settings()
|
||||
migrate_data()
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue