diff options
Diffstat (limited to 'actionpack/lib/action_view/base.rb')
-rw-r--r-- | actionpack/lib/action_view/base.rb | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/actionpack/lib/action_view/base.rb b/actionpack/lib/action_view/base.rb index 84f2c45f4e..40b808a61e 100644 --- a/actionpack/lib/action_view/base.rb +++ b/actionpack/lib/action_view/base.rb @@ -256,16 +256,11 @@ module ActionView #:nodoc: elsif options[:partial] render_partial(options[:partial], ActionView::Base::ObjectWrapper.new(options[:object]), options[:locals]) elsif options[:inline] - template = InlineTemplate.new(self, options[:inline], options[:locals], options[:type]) - render_template(template) + render_inline(options[:inline], options[:locals], options[:type]) end end end - def render_template(template) #:nodoc: - template.render_template - end - # Returns true is the file may be rendered implicitly. def file_public?(template_path)#:nodoc: template_path.split('/').last[0,1] != '_' @@ -323,6 +318,10 @@ module ActionView #:nodoc: Template.new(self, template_path, use_full_path, local_assigns).render_template end + def render_inline(text, local_assigns = {}, type = nil) + InlineTemplate.new(self, text, local_assigns, type).render_template + end + def wrap_content_for_layout(content) original_content_for_layout, @content_for_layout = @content_for_layout, content yield |