From f2d8d13c6495f2a9b3bbf3b50d869c0e5b25c207 Mon Sep 17 00:00:00 2001 From: Joshua Peek Date: Mon, 25 Aug 2008 21:44:21 -0500 Subject: Performance: Cache modules that extend the view context for JavaScriptGenerator --- actionpack/lib/action_view/helpers/prototype_helper.rb | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'actionpack/lib/action_view/helpers') diff --git a/actionpack/lib/action_view/helpers/prototype_helper.rb b/actionpack/lib/action_view/helpers/prototype_helper.rb index 4c3a8311a5..09dbb67c0a 100644 --- a/actionpack/lib/action_view/helpers/prototype_helper.rb +++ b/actionpack/lib/action_view/helpers/prototype_helper.rb @@ -588,9 +588,7 @@ module ActionView private def include_helpers_from_context - @context.extended_by.each do |mod| - extend mod unless mod.name =~ /^ActionView::Helpers/ - end + @context.send(:extended_by_without_helpers).each { |mod| extend mod } extend GeneratorMethods end -- cgit v1.2.3