some problems with transfer options
simple_fields_for don't passed options and it's created some problems like this: ryanb/nested_form#219 ryanb/nested_form#226 because if wrapper option is false, then wrapper not transfered
This commit is contained in:
parent
e8bb7b391b
commit
c439ab33c8
|
@ -194,7 +194,7 @@ module SimpleForm
|
||||||
# end
|
# end
|
||||||
def simple_fields_for(*args, &block)
|
def simple_fields_for(*args, &block)
|
||||||
options = args.extract_options!
|
options = args.extract_options!
|
||||||
options[:wrapper] ||= self.options[:wrapper]
|
options[:wrapper] = self.options[:wrapper] if options[:wrapper].nil?
|
||||||
options[:defaults] ||= self.options[:defaults]
|
options[:defaults] ||= self.options[:defaults]
|
||||||
|
|
||||||
if self.class < ActionView::Helpers::FormBuilder
|
if self.class < ActionView::Helpers::FormBuilder
|
||||||
|
|
Loading…
Reference in New Issue