diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2005-05-06 05:09:01 +0000 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2005-05-06 05:09:01 +0000 |
commit | 358a6693909009556f493f0c29e344af4acc3275 (patch) | |
tree | 9bc1c9f7a0110285da99cae66a566b0836c29dd1 /actionpack/lib/action_controller | |
parent | 421045e2ff9e0f2077b4f1f23541f197b3249bd7 (diff) | |
download | rails-358a6693909009556f493f0c29e344af4acc3275.tar.gz rails-358a6693909009556f493f0c29e344af4acc3275.tar.bz2 rails-358a6693909009556f493f0c29e344af4acc3275.zip |
Added better error handling for regexp caching expiration
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1288 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'actionpack/lib/action_controller')
-rw-r--r-- | actionpack/lib/action_controller/caching.rb | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/actionpack/lib/action_controller/caching.rb b/actionpack/lib/action_controller/caching.rb index 28618e2427..7749b07815 100644 --- a/actionpack/lib/action_controller/caching.rb +++ b/actionpack/lib/action_controller/caching.rb @@ -375,7 +375,13 @@ module ActionController #:nodoc: def delete_matched(matcher, options) #:nodoc: search_dir(@cache_path) do |f| - File.delete(f) rescue nil if f =~ matcher + if f =~ matcher + begin + File.delete(f) + rescue Object => e + Base.logger.info "Couldn't expire cache: #{f} (#{e.message})" unless Base.logger.nil? + end + end end end |