aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/lib/abstract_controller/helpers.rb
diff options
context:
space:
mode:
authorJeremy Kemper <jeremy@bitsweat.net>2010-01-31 18:32:28 -0800
committerJeremy Kemper <jeremy@bitsweat.net>2010-02-01 02:02:42 -0800
commite5ab4b0d07ade8d89d633ca744c0eafbc53ee921 (patch)
treeaa2480b38f79e623b98da0274695f99db73bff20 /actionpack/lib/abstract_controller/helpers.rb
parent8ae25a8e41168801590fdb95891cc5990b4db21c (diff)
downloadrails-e5ab4b0d07ade8d89d633ca744c0eafbc53ee921.tar.gz
rails-e5ab4b0d07ade8d89d633ca744c0eafbc53ee921.tar.bz2
rails-e5ab4b0d07ade8d89d633ca744c0eafbc53ee921.zip
Convert to class_attribute
Diffstat (limited to 'actionpack/lib/abstract_controller/helpers.rb')
-rw-r--r--actionpack/lib/abstract_controller/helpers.rb10
1 files changed, 6 insertions, 4 deletions
diff --git a/actionpack/lib/abstract_controller/helpers.rb b/actionpack/lib/abstract_controller/helpers.rb
index eb621c0865..578b884a4d 100644
--- a/actionpack/lib/abstract_controller/helpers.rb
+++ b/actionpack/lib/abstract_controller/helpers.rb
@@ -1,4 +1,6 @@
require 'active_support/dependencies'
+require 'active_support/core_ext/class/attribute'
+require 'active_support/core_ext/module/delegation'
module AbstractController
module Helpers
@@ -12,10 +14,10 @@ module AbstractController
end
included do
- extlib_inheritable_accessor(:_helpers) { Module.new }
- extlib_inheritable_accessor(:_helper_serial) do
- AbstractController::Helpers.next_serial
- end
+ class_attribute :_helpers, :_helper_serial
+ delegate :_helpers, :to => :'self.class'
+ self._helpers = Module.new
+ self._helper_serial = ::AbstractController::Helpers.next_serial
end
module ClassMethods