aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--actionpack/CHANGELOG2
-rw-r--r--actionpack/lib/action_view/base.rb3
2 files changed, 4 insertions, 1 deletions
diff --git a/actionpack/CHANGELOG b/actionpack/CHANGELOG
index d4cfc6edfa..4f32e39822 100644
--- a/actionpack/CHANGELOG
+++ b/actionpack/CHANGELOG
@@ -1,5 +1,7 @@
*SVN*
+* Fixed that cached template loading would still check the file system to see if the file existed #258 [Andreas Schwarz]
+
* Added options to tailor header tag, div id, and div class on ActiveRecordHelper#error_messages_for [josh]
* Added graceful handling of non-alphanumeric names and misplaced brackets in input parameters [bitsweat]
diff --git a/actionpack/lib/action_view/base.rb b/actionpack/lib/action_view/base.rb
index 84c8040760..683cb8af6f 100644
--- a/actionpack/lib/action_view/base.rb
+++ b/actionpack/lib/action_view/base.rb
@@ -238,7 +238,8 @@ module ActionView #:nodoc:
end
def template_exists?(template_path, extension)
- FileTest.exists?(full_template_path(template_path, extension))
+ (cache_template_loading && @@loaded_templates.has_key?(template_path)) ||
+ FileTest.exists?(full_template_path(template_path, extension))
end
def read_template_file(template_path)