aboutsummaryrefslogtreecommitdiffstats
path: root/guides
diff options
context:
space:
mode:
authoryuuji.yaginuma <yuuji.yaginuma@gmail.com>2015-10-03 19:12:53 +0900
committeryuuji.yaginuma <yuuji.yaginuma@gmail.com>2015-10-03 19:26:24 +0900
commit70b09eda034766efcd2cac9280d42c7bbaaadff9 (patch)
tree2eb835fc7e6e94aa99ef343c421542d1bdddc67d /guides
parent9db73a2591e43d1851411727d6594a72efa35663 (diff)
downloadrails-70b09eda034766efcd2cac9280d42c7bbaaadff9.tar.gz
rails-70b09eda034766efcd2cac9280d42c7bbaaadff9.tar.bz2
rails-70b09eda034766efcd2cac9280d42c7bbaaadff9.zip
use class to specify the middleware [ci skip]
using string for middleware class names is deprecated in 83b767cef90abfc4c2ee9f4b451b0215501fae9a
Diffstat (limited to 'guides')
-rw-r--r--guides/source/rails_on_rack.md10
1 files changed, 5 insertions, 5 deletions
diff --git a/guides/source/rails_on_rack.md b/guides/source/rails_on_rack.md
index 0db90fedb3..87f869aff3 100644
--- a/guides/source/rails_on_rack.md
+++ b/guides/source/rails_on_rack.md
@@ -171,7 +171,7 @@ Add the following lines to your application configuration:
```ruby
# config/application.rb
-config.middleware.delete "Rack::Lock"
+config.middleware.delete Rack::Lock
```
And now if you inspect the middleware stack, you'll find that `Rack::Lock` is
@@ -191,16 +191,16 @@ If you want to remove session related middleware, do the following:
```ruby
# config/application.rb
-config.middleware.delete "ActionDispatch::Cookies"
-config.middleware.delete "ActionDispatch::Session::CookieStore"
-config.middleware.delete "ActionDispatch::Flash"
+config.middleware.delete ActionDispatch::Cookies
+config.middleware.delete ActionDispatch::Session::CookieStore
+config.middleware.delete ActionDispatch::Flash
```
And to remove browser related middleware,
```ruby
# config/application.rb
-config.middleware.delete "Rack::MethodOverride"
+config.middleware.delete Rack::MethodOverride
```
### Internal Middleware Stack