Permalink
Browse files

In new base Rails2Compatibility, move @template assignment to right b…

…efore the first action is processed.
  • Loading branch information...
Carl Lerche
Carl Lerche committed May 26, 2009
1 parent cd8fb18 commit cbb0724f0d0d51a8097ba707517dcf1d09b07a31
Showing with 6 additions and 6 deletions.
  1. +6 −6 actionpack/lib/action_controller/new_base/compatibility.rb
@@ -69,7 +69,12 @@ def assign_shortcuts(*) end
# TODO: Remove this after we flip
def template
- _action_view
+ @template ||= _action_view
+ end
+
+ def process_action(*)
+ template
+ super
end
module ClassMethods
@@ -83,11 +88,6 @@ def cache_store=(store_option)
@@cache_store = ActiveSupport::Cache.lookup_store(store_option)
end
end
-
- def initialize(*)
- super
- @template = _action_view
- end
def render_to_body(options)
if options.is_a?(Hash) && options.key?(:template)

0 comments on commit cbb0724

Please sign in to comment.