ActiveSupport.on_load(:action_controller) do
  # -*- coding: utf-8 -*-
  require 'jpmobile/docomo_guid'
  require 'jpmobile/filter'
  require 'jpmobile/helpers'
  require 'jpmobile/hook_action_controller'
  require 'jpmobile/hook_action_view'
  require 'jpmobile/trans_sid'

  # MobileCarrierのみデフォルトで有効
  ::Rails.application.middleware.insert_before('ActionDispatch::ParamsParser', Jpmobile::Rack::MobileCarrier)

  module Rails
    class Application
      class Configuration
        def jpmobile
          @jpmobile ||= ::Jpmobile::Configuration.new
        end
      end
    end
  end
end

# -*- coding: utf-8 -*-
ActiveSupport.on_load(:before_configuration) do
  require 'jpmobile/docomo_guid'
  require 'jpmobile/filter'
  require 'jpmobile/helpers'
  require 'jpmobile/hook_action_controller'
  require 'jpmobile/hook_action_view'
  require 'jpmobile/trans_sid'

  # MobileCarrierのみデフォルトで有効
  ::Rails.application.middleware.insert_before('ActionDispatch::ParamsParser', Jpmobile::Rack::MobileCarrier)

  module Rails
    class Application
      class Configuration
        def jpmobile
          @jpmobile ||= ::Jpmobile::Configuration.new
        end
      end
    end
  end
end

Fix hook point of on_load
Fix hook point of on_load

Signed-off-by: Shin-ichiro OGAWA <944c384b665d30ce41dfae275e7ba3c4ca979271@gmail.com>
