From f0e9fd74aed3d74e6ae8f53dbdcd1340d238cb57 Mon Sep 17 00:00:00 2001 From: David Heinemeier Hansson Date: Fri, 1 Jul 2005 18:21:29 +0000 Subject: Make render(:inline) use locals #1556 [Michael Shuerig] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1584 5ecf4fe2-1ee6-0310-87b1-e25e094e27de --- actionpack/lib/action_controller/base.rb | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'actionpack/lib/action_controller') diff --git a/actionpack/lib/action_controller/base.rb b/actionpack/lib/action_controller/base.rb index 2e0d554a55..91ebc7e69d 100755 --- a/actionpack/lib/action_controller/base.rb +++ b/actionpack/lib/action_controller/base.rb @@ -471,7 +471,14 @@ module ActionController #:nodoc: render(options.merge({ :file => options[:template], :use_full_path => true })) elsif options[:inline] - render(options.merge({ :text => @template.render_template(options[:type] || :rhtml, options[:inline]) })) + render(options.merge({ + :text => + @template.render_template( + options[:type] || :rhtml, + options[:inline], + options[:locals] || {} + ) + })) elsif options[:action] render(options.merge({ :template => default_template_name(options[:action]) })) -- cgit v1.2.3