Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

fix the railtie to properly load the unpermitted parameters action co…

…nfig
  • Loading branch information...
commit c4e25f367ad5ea8bb6e522130d9a809d188bb581 1 parent ae3826f
@dmathieu dmathieu authored
Showing with 2 additions and 2 deletions.
  1. +2 −2 lib/strong_parameters/railtie.rb
View
4 lib/strong_parameters/railtie.rb
@@ -8,8 +8,8 @@ class Railtie < ::Rails::Railtie
config.generators.scaffold_controller = :strong_parameters_controller
end
- initializer "strong_parameters.config", :before => "active_controller.set_configs" do |app|
- ActionController::Parameters.action_on_unpermitted_parameters = options.delete(:action_on_unpermitted_parameters) do
+ initializer "strong_parameters.config", :before => "action_controller.set_configs" do |app|
+ ActionController::Parameters.action_on_unpermitted_parameters = app.config.action_controller.delete(:action_on_unpermitted_parameters) do
(Rails.env.test? || Rails.env.development?) ? :log : false
end
end
Please sign in to comment.
Something went wrong with that request. Please try again.