diff options
author | Andrew White <andyw@pixeltrix.co.uk> | 2009-02-05 19:56:22 -0600 |
---|---|---|
committer | Joshua Peek <josh@joshpeek.com> | 2009-02-05 19:56:22 -0600 |
commit | bccd2c54b2c7708f881faf9c9464dcf29bd30bef (patch) | |
tree | 940a4d59b8fb44d4ff46d202f820e3a9ad36b96a /actionpack/lib/action_view | |
parent | f75b98d67ed9ef85d20858a1d24ee6767d64ece6 (diff) | |
download | rails-bccd2c54b2c7708f881faf9c9464dcf29bd30bef.tar.gz rails-bccd2c54b2c7708f881faf9c9464dcf29bd30bef.tar.bz2 rails-bccd2c54b2c7708f881faf9c9464dcf29bd30bef.zip |
Use Path rather than EagerPath when cache_classes == false so other view paths are properly recompiled in development mode [#1764 state:resolved]
Signed-off-by: Joshua Peek <josh@joshpeek.com>
Diffstat (limited to 'actionpack/lib/action_view')
-rw-r--r-- | actionpack/lib/action_view/paths.rb | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/actionpack/lib/action_view/paths.rb b/actionpack/lib/action_view/paths.rb index ee26542a07..c7d6fd696a 100644 --- a/actionpack/lib/action_view/paths.rb +++ b/actionpack/lib/action_view/paths.rb @@ -2,7 +2,11 @@ module ActionView #:nodoc: class PathSet < Array #:nodoc: def self.type_cast(obj) if obj.is_a?(String) - Template::EagerPath.new(obj) + if !Object.const_defined?(:Rails) || Rails.configuration.cache_classes + Template::EagerPath.new(obj) + else + Template::Path.new(obj) + end else obj end |