Prepare to support ruby 3.3.

This commit is contained in:
邱博亞 2024-02-28 19:19:32 +08:00
parent b2c3627afa
commit 6c2a5caf30
1 changed files with 72 additions and 70 deletions

View File

@ -1,6 +1,7 @@
module EPaper module EPaper
class Engine < ::Rails::Engine class Engine < ::Rails::Engine
initializer "e_paper" do initializer "e_paper" do
Rails.application.config.to_prepare do
env_pwd = ENV['PWD'] env_pwd = ENV['PWD']
begin begin
require File.expand_path('app/models/sub_part.rb', env_pwd) require File.expand_path('app/models/sub_part.rb', env_pwd)
@ -79,4 +80,5 @@ module EPaper
end end
end end
end end
end
end end