Skip to content
This repository
Browse code

Merge pull request #5246 from lest/patch-2

simplify namespace assignment in fields_for
  • Loading branch information...
commit ecf4db15bc6d6574ce93b1658435e162c09d80a1 2 parents 833181f + 4e8fbc0
José Valim josevalim authored

Showing 1 changed file with 1 addition and 1 deletion. Show diff stats Hide diff stats

  1. +1 1  actionpack/lib/action_view/helpers/form_helper.rb
2  actionpack/lib/action_view/helpers/form_helper.rb
@@ -1016,7 +1016,7 @@ def fields_for(record_name, record_object = nil, fields_options = {}, &block)
1016 1016 fields_options, record_object = record_object, nil if record_object.is_a?(Hash) && record_object.extractable_options?
1017 1017 fields_options[:builder] ||= options[:builder]
1018 1018 fields_options[:parent_builder] = self
1019   - fields_options[:namespace] = fields_options[:parent_builder].options[:namespace]
  1019 + fields_options[:namespace] = options[:namespace]
1020 1020
1021 1021 case record_name
1022 1022 when String, Symbol

0 comments on commit ecf4db1

Please sign in to comment.
Something went wrong with that request. Please try again.