aboutsummaryrefslogtreecommitdiffstats
path: root/railties/lib
diff options
context:
space:
mode:
authorDavid Heinemeier Hansson <david@loudthinking.com>2009-12-21 11:28:16 -0800
committerDavid Heinemeier Hansson <david@loudthinking.com>2009-12-21 11:28:16 -0800
commitfa8849a573aa98750fc5fdacf557d973b85072ca (patch)
tree0c343cdc94eb861413b3f70b1ecf329468dce684 /railties/lib
parentc06aff0a7e42868e9788d6cefe5ce49e93cbf45b (diff)
parentf09ad263cabe2e781c1994b85375fee8deba4317 (diff)
downloadrails-fa8849a573aa98750fc5fdacf557d973b85072ca.tar.gz
rails-fa8849a573aa98750fc5fdacf557d973b85072ca.tar.bz2
rails-fa8849a573aa98750fc5fdacf557d973b85072ca.zip
Merge branch 'master' of github.com:rails/rails
Diffstat (limited to 'railties/lib')
-rw-r--r--railties/lib/rails/generators/rails/app/templates/app/controllers/application_controller.rb8
-rw-r--r--railties/lib/rails/generators/rails/app/templates/config/routes.rb10
2 files changed, 7 insertions, 11 deletions
diff --git a/railties/lib/rails/generators/rails/app/templates/app/controllers/application_controller.rb b/railties/lib/rails/generators/rails/app/templates/app/controllers/application_controller.rb
index 6635a3f487..e7991fff92 100644
--- a/railties/lib/rails/generators/rails/app/templates/app/controllers/application_controller.rb
+++ b/railties/lib/rails/generators/rails/app/templates/app/controllers/application_controller.rb
@@ -2,9 +2,7 @@
# Likewise, all the methods added will be available for all controllers.
class ApplicationController < ActionController::Base
- helper :all # include all helpers, all the time
- protect_from_forgery # See ActionController::RequestForgeryProtection for details
-
- # Scrub sensitive parameters from your log
- # filter_parameter_logging :password
+ helper :all
+ protect_from_forgery
+ filter_parameter_logging :password, :password_confirmation
end
diff --git a/railties/lib/rails/generators/rails/app/templates/config/routes.rb b/railties/lib/rails/generators/rails/app/templates/config/routes.rb
index e0f9ca8a12..0d1b6bab4f 100644
--- a/railties/lib/rails/generators/rails/app/templates/config/routes.rb
+++ b/railties/lib/rails/generators/rails/app/templates/config/routes.rb
@@ -3,7 +3,7 @@ ActionController::Routing::Routes.draw do |map|
# first created -> highest priority.
# Sample of regular route:
- # match 'products/:id', :to => 'catalog#view'
+ # match 'products/:id' => 'catalog#view'
# Keep in mind you can assign values other than :controller and :action
# Sample of named route:
@@ -52,9 +52,7 @@ ActionController::Routing::Routes.draw do |map|
# See how all your routes lay out with "rake routes"
- # Install the default route as the lowest priority.
- # Note: The default route make all actions in every controller accessible
- # via GET requests. You should consider removing or commenting it out if
- # you're using named routes and resources.
- match ':controller(/:action(/:id(.:format)))'
+ # This is a legacy wild controller route that's not recommended for RESTful applications.
+ # Note: This route will make all actions in every controller accessible via GET requests.
+ # match ':controller(/:action(/:id(.:format)))'
end