Just initialize options with an empty hash
This commit is contained in:
parent
6362538815
commit
d7ec94f665
@ -294,10 +294,9 @@ module FormHelper
|
||||
#
|
||||
# If you don't need to attach a form to a model instance, then check out
|
||||
# FormTagHelper#form_tag.
|
||||
def form_for(record, options = nil, &proc)
|
||||
def form_for(record, options = {}, &proc)
|
||||
raise ArgumentError, "Missing block" unless block_given?
|
||||
|
||||
options ||= {}
|
||||
options[:html] ||= {}
|
||||
|
||||
case record
|
||||
|
Loading…
Reference in New Issue
Block a user