1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00
rails--rails/actionpack/lib/action_dispatch/railtie.rb

15 lines
No EOL
475 B
Ruby

require "action_dispatch"
require "rails"
module ActionDispatch
class Railtie < Rails::Railtie
railtie_name :action_dispatch
# Prepare dispatcher callbacks and run 'prepare' callbacks
initializer "action_dispatch.prepare_dispatcher" do |app|
# TODO: This used to say unless defined?(Dispatcher). Find out why and fix.
require 'rails/dispatcher'
ActionDispatch::Callbacks.to_prepare { app.routes_reloader.reload_if_changed }
end
end
end