From 348de3a06e802fb651d675aa3a9b2aaaf48ec572 Mon Sep 17 00:00:00 2001 From: Eugene Gilburg Date: Fri, 18 Jul 2014 20:37:17 -0700 Subject: marking private methods which dont work if called on their own anyways --- actionview/lib/action_view/renderer/partial_renderer.rb | 2 ++ actionview/lib/action_view/renderer/template_renderer.rb | 4 +++- 2 files changed, 5 insertions(+), 1 deletion(-) (limited to 'actionview/lib') diff --git a/actionview/lib/action_view/renderer/partial_renderer.rb b/actionview/lib/action_view/renderer/partial_renderer.rb index a8d2094f72..0407632435 100644 --- a/actionview/lib/action_view/renderer/partial_renderer.rb +++ b/actionview/lib/action_view/renderer/partial_renderer.rb @@ -312,6 +312,8 @@ module ActionView end end + private + def render_collection return nil if @collection.blank? diff --git a/actionview/lib/action_view/renderer/template_renderer.rb b/actionview/lib/action_view/renderer/template_renderer.rb index 7bf527bfda..f3a48ecfa0 100644 --- a/actionview/lib/action_view/renderer/template_renderer.rb +++ b/actionview/lib/action_view/renderer/template_renderer.rb @@ -14,8 +14,10 @@ module ActionView render_template(template, options[:layout], options[:locals]) end + private + # Determine the template to be rendered using the given options. - def determine_template(options) #:nodoc: + def determine_template(options) keys = options.fetch(:locals, {}).keys if options.key?(:body) -- cgit v1.2.3