Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fix name of nested attributes option include_id

The option to disable including a hidden ID field on a `fields_for` nested association was incorrectly documented as `hidden_field_id` instead of `include_id`
  • Loading branch information...
commit 71273430ce3f97785f688364f5495cc105cd1860 1 parent bfc8ffa
@stormsilver stormsilver authored
Showing with 2 additions and 2 deletions.
  1. +2 −2 actionpack/lib/action_view/helpers/form_helper.rb
View
4 actionpack/lib/action_view/helpers/form_helper.rb
@@ -692,7 +692,7 @@ def apply_form_for_options!(record, object, options) #:nodoc:
#
# Note that fields_for will automatically generate a hidden field
# to store the ID of the record. There are circumstances where this
- # hidden field is not needed and you can pass <tt>hidden_field_id: false</tt>
+ # hidden field is not needed and you can pass <tt>include_id: false</tt>
# to prevent fields_for from rendering it automatically.
def fields_for(record_name, record_object = nil, options = {}, &block)
builder = instantiate_builder(record_name, record_object, options)
@@ -1507,7 +1507,7 @@ def #{selector}(method, options = {}) # def text_field(method, options = {})
#
# Note that fields_for will automatically generate a hidden field
# to store the ID of the record. There are circumstances where this
- # hidden field is not needed and you can pass <tt>hidden_field_id: false</tt>
+ # hidden field is not needed and you can pass <tt>include_id: false</tt>
# to prevent fields_for from rendering it automatically.
def fields_for(record_name, record_object = nil, fields_options = {}, &block)
fields_options, record_object = record_object, nil if record_object.is_a?(Hash) && record_object.extractable_options?
Please sign in to comment.
Something went wrong with that request. Please try again.