diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2004-12-29 21:12:47 +0000 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2004-12-29 21:12:47 +0000 |
commit | 84d5519b74f831d31caf00a018ca0c3b60ebb643 (patch) | |
tree | d80dd4d70106e04d11ca144979e9df6413284c0c /actionpack/lib/action_controller | |
parent | 8efa1513ed49783d8a7fd1dfccee93fa5e5f0d81 (diff) | |
download | rails-84d5519b74f831d31caf00a018ca0c3b60ebb643.tar.gz rails-84d5519b74f831d31caf00a018ca0c3b60ebb643.tar.bz2 rails-84d5519b74f831d31caf00a018ca0c3b60ebb643.zip |
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@276 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'actionpack/lib/action_controller')
-rw-r--r-- | actionpack/lib/action_controller/dependencies.rb | 19 |
1 files changed, 0 insertions, 19 deletions
diff --git a/actionpack/lib/action_controller/dependencies.rb b/actionpack/lib/action_controller/dependencies.rb index 14fb0147b6..e1ede3d42a 100644 --- a/actionpack/lib/action_controller/dependencies.rb +++ b/actionpack/lib/action_controller/dependencies.rb @@ -1,22 +1,8 @@ -unless Object.respond_to?(:require_dependency) - Object.send(:define_method, :require_dependency) { |file_name| ActionController::Base.require_dependency(file_name) } -end - module ActionController #:nodoc: module Dependencies #:nodoc: def self.append_features(base) super - - base.class_eval do - # When turned on (which is default), all dependencies are included using "load". This mean that any change is instant in cached - # environments like mod_ruby or FastCGI. When set to false, "require" is used, which is faster but requires server restart to - # be effective. - @@reload_dependencies = true - cattr_accessor :reload_dependencies - end - base.class_eval { class << self; alias_method :inherited_without_model, :inherited; end } - base.extend(ClassMethods) end @@ -41,11 +27,6 @@ module ActionController #:nodoc: # # helper :post (already required) # end module ClassMethods - # Loads the <tt>file_name</tt> if reload_dependencies is true or requires if it's false. - def require_dependency(file_name) - reload_dependencies ? silence_warnings { load("#{file_name}.rb") } : require(file_name) - end - # Specifies a variable number of models that this controller depends on. Models are normally Active Record classes or a similar # backend for modelling entity classes. def model(*models) |