diff options
author | Christopher Baines <mail@cbaines.net> | 2018-03-26 22:11:38 +0100 |
---|---|---|
committer | Christopher Baines <mail@cbaines.net> | 2018-04-03 21:57:39 +0100 |
commit | 4f78b4eb0738b003e4ba6f96e0ddc3188f1d3d23 (patch) | |
tree | 1c1c1948bca0f03fd2cc1014734b6fbe12c9eb87 /config | |
parent | 4e34ede0d390d5158188d20b1dbf6d87b6c60b9f (diff) | |
download | govuk-mini-environment-admin-4f78b4eb0738b003e4ba6f96e0ddc3188f1d3d23.tar govuk-mini-environment-admin-4f78b4eb0738b003e4ba6f96e0ddc3188f1d3d23.tar.gz |
Error on unpermitted strong parameters
Unless running in the production environment. This helps with
development as errors are caught earlier.
Diffstat (limited to 'config')
-rw-r--r-- | config/initializers/strong_params.rb | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/config/initializers/strong_params.rb b/config/initializers/strong_params.rb new file mode 100644 index 0000000..07415fe --- /dev/null +++ b/config/initializers/strong_params.rb @@ -0,0 +1,3 @@ +unless Rails.env.production? + ActionController::Parameters.action_on_unpermitted_parameters = :raise +end |