Skip to content

Commit 4af74ff

Browse files
authored
Merge pull request rails#41267 from arjan0307/patch-4
Provide a working example for a filter_parameters lambda
2 parents f25ce17 + 46f2c6e commit 4af74ff

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

railties/test/application/configuration_test.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -468,7 +468,7 @@ class Comment < ActiveRecord::Base
468468
test "filter_parameters should be able to set via config.filter_parameters" do
469469
add_to_config <<-RUBY
470470
config.filter_parameters += [ :foo, 'bar', lambda { |key, value|
471-
value = value.reverse if /baz/.match?(key)
471+
value.reverse! if /baz/.match?(key)
472472
}]
473473
RUBY
474474

0 commit comments

Comments
 (0)