diff options
author | Yehuda Katz <wycats@gmail.com> | 2009-03-03 17:20:57 -0800 |
---|---|---|
committer | Yehuda Katz <wycats@gmail.com> | 2009-03-03 17:20:57 -0800 |
commit | f8088d7def4bf413533d85a1565be58231c3d23e (patch) | |
tree | c359ef72b9d69324aef1ffa2282138edd0f148bb /actionpack/lib/action_controller | |
parent | 6001cea5d70344d4c13b5cff94ee853f5f5462ce (diff) | |
download | rails-f8088d7def4bf413533d85a1565be58231c3d23e.tar.gz rails-f8088d7def4bf413533d85a1565be58231c3d23e.tar.bz2 rails-f8088d7def4bf413533d85a1565be58231c3d23e.zip |
memoize correctly ;)
Diffstat (limited to 'actionpack/lib/action_controller')
-rw-r--r-- | actionpack/lib/action_controller/abstract/helpers.rb | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/actionpack/lib/action_controller/abstract/helpers.rb b/actionpack/lib/action_controller/abstract/helpers.rb index b942a7ea80..1947c360b8 100644 --- a/actionpack/lib/action_controller/abstract/helpers.rb +++ b/actionpack/lib/action_controller/abstract/helpers.rb @@ -14,8 +14,11 @@ module AbstractController end def _action_view - av = super - av.helpers.send(:include, master_helper_module) + @_action_view ||= begin + av = super + av.helpers.send(:include, master_helper_module) + av + end end module ClassMethods |