From 83f62a069e6723c994365855bd9509d5b1a218bc Mon Sep 17 00:00:00 2001 From: Rafael Magana Date: Tue, 22 May 2012 21:33:49 -0500 Subject: use ApplicationName::Application instead of ActionController::Dispatcher.new since Dispatcher class no longer exists --- guides/source/rails_on_rack.textile | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/guides/source/rails_on_rack.textile b/guides/source/rails_on_rack.textile index d8910cf1d0..0080982b67 100644 --- a/guides/source/rails_on_rack.textile +++ b/guides/source/rails_on_rack.textile @@ -23,7 +23,7 @@ h3. Rails on Rack h4. Rails Application's Rack Object -ActionController::Dispatcher.new is the primary Rack application object of a Rails application. Any Rack compliant web server should be using +ActionController::Dispatcher.new+ object to serve a Rails application. +ApplicationName::Application is the primary Rack application object of a Rails application. Any Rack compliant web server should be using +ApplicationName::Application+ object to serve a Rails application. h4. +rails server+ @@ -36,7 +36,7 @@ app = Rack::Builder.new { use Rails::Rack::LogTailer unless options[:detach] use Rails::Rack::Debugger if options[:debugger] use ActionDispatch::Static - run ActionController::Dispatcher.new + run ApplicationName::Application }.to_app @@ -57,7 +57,7 @@ require "config/environment" use Rails::Rack::LogTailer use ActionDispatch::Static -run ActionController::Dispatcher.new +run ApplicationName::Application And start the server: @@ -111,7 +111,7 @@ use ActionDispatch::Head use Rack::ConditionalGet use Rack::ETag use ActionDispatch::BestStandardsSupport -run Blog::Application.routes +run ApplicationName::Application.routes Purpose of each of this middlewares is explained in the "Internal Middlewares":#internal-middleware-stack section. @@ -172,7 +172,7 @@ use ActionDispatch::Static use # use Rack::Runtime ... -run Myapp::Application.routes +run Blog::Application.routes h4. Internal Middleware Stack @@ -264,7 +264,7 @@ config.middleware.clear # config.ru use MyOwnStackFromScratch -run ActionController::Dispatcher.new +run ApplicationName::Application h3. Resources -- cgit v1.2.3