diff --git a/config/initializers/access_token_authentication.rb b/config/initializers/access_token_authentication.rb index f650b1b5e2..dfdcee839b 100644 --- a/config/initializers/access_token_authentication.rb +++ b/config/initializers/access_token_authentication.rb @@ -1,6 +1,6 @@ # frozen_string_literal: true -Rails.application.config.after_initialize do +Rails.application.config.to_prepare do ActiveSupport.on_load(:active_record) do if defined?(ActiveRecord::ConnectionAdapters::Mysql2Adapter) ActiveRecord::ConnectionAdapters::Mysql2Adapter.class_eval do diff --git a/config/initializers/money.rb b/config/initializers/money.rb index bd750ff6b9..b73196d453 100644 --- a/config/initializers/money.rb +++ b/config/initializers/money.rb @@ -1,6 +1,6 @@ require 'three_scale/money_conversions' -Rails.application.config.after_initialize do +Rails.application.config.to_prepare do ActionController::Base.helper(ThreeScale::MoneyHelper) ActiveSupport.on_load(:active_record) do