From d7ec94f66580abceffd313b943636ef113ffa662 Mon Sep 17 00:00:00 2001 From: Santiago Pastorino Date: Wed, 3 Nov 2010 17:20:02 -0200 Subject: Just initialize options with an empty hash --- actionpack/lib/action_view/helpers/form_helper.rb | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/actionpack/lib/action_view/helpers/form_helper.rb b/actionpack/lib/action_view/helpers/form_helper.rb index d6e175c7e8..80a872068d 100644 --- a/actionpack/lib/action_view/helpers/form_helper.rb +++ b/actionpack/lib/action_view/helpers/form_helper.rb @@ -294,10 +294,9 @@ module ActionView # # 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 -- cgit v1.2.3