diff options
author | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2012-03-04 20:53:59 -0300 |
---|---|---|
committer | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2012-03-04 22:37:04 -0300 |
commit | f604a6368b3a39b0035d6fe964802a4c35eb958a (patch) | |
tree | bd89cd48b48c6adf3965c689a2de5e6cda17f076 /railties/lib/rails | |
parent | 06a3a8a458e70c1b6531ac53c57a302b162fd736 (diff) | |
download | rails-f604a6368b3a39b0035d6fe964802a4c35eb958a.tar.gz rails-f604a6368b3a39b0035d6fe964802a4c35eb958a.tar.bz2 rails-f604a6368b3a39b0035d6fe964802a4c35eb958a.zip |
Only add the whitelist_attributes option if ActiveRecord is present
Conflicts:
railties/test/generators/app_generator_test.rb
railties/test/isolation/abstract_unit.rb
Diffstat (limited to 'railties/lib/rails')
-rw-r--r-- | railties/lib/rails/generators/rails/app/templates/config/application.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/railties/lib/rails/generators/rails/app/templates/config/application.rb b/railties/lib/rails/generators/rails/app/templates/config/application.rb index 41e2d5dcc5..21e7a4b283 100644 --- a/railties/lib/rails/generators/rails/app/templates/config/application.rb +++ b/railties/lib/rails/generators/rails/app/templates/config/application.rb @@ -58,7 +58,7 @@ module <%= app_const_base %> # This will create an empty whitelist of attributes available for mass-assignment for all models # in your app. As such, your models will need to explicitly whitelist or blacklist accessible # parameters by using an attr_accessible or attr_protected declaration. - config.active_record.whitelist_attributes = true + <%= comment_if :skip_active_record %>config.active_record.whitelist_attributes = true <% unless options.skip_sprockets? -%> # Enable the asset pipeline |