Prepare to support ruby 3.3.
This commit is contained in:
parent
a790cc0c72
commit
9853601ffb
|
@ -2,8 +2,9 @@ module Feeds
|
|||
class Engine < ::Rails::Engine
|
||||
initializer "feeds" do
|
||||
Rails.application.config.to_prepare do
|
||||
gem_root = Feeds::Engine.root
|
||||
if ENV['worker_num']=='0' && File.basename($0) != 'rake' && !Rails.const_defined?('Console')
|
||||
require File.expand_path('../../../app/models/site_feed_setting', __FILE__)
|
||||
require File.join(gem_root, 'app/models/site_feed_setting')
|
||||
if defined?(SiteFeedSetting)
|
||||
if SiteFeedSetting.count==0
|
||||
SiteFeedSetting.create
|
||||
|
@ -52,7 +53,6 @@ module Feeds
|
|||
end
|
||||
|
||||
end
|
||||
gem_root = Feeds::Engine.root
|
||||
gem_tmp = File.join(gem_root, 'tmp')
|
||||
f = File.join(gem_tmp, "install_bash")
|
||||
if File.exist?(f)
|
||||
|
|
Loading…
Reference in New Issue