Skip to content

Commit

Permalink
Expiring a cache that doesnt exist is bliss not bad
Browse files Browse the repository at this point in the history
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1895 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
  • Loading branch information
dhh committed Jul 22, 2005
1 parent 34f9d30 commit 0223565
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions actionpack/lib/action_controller/caching.rb
Expand Up @@ -372,7 +372,7 @@ def read(name, options = {}) #:nodoc:
def delete(name, options) #:nodoc:
File.delete(real_file_path(name))
rescue SystemCallError => e
Base.logger.error "Couldn't expire cache #{name} (#{e.message})" unless Base.logger.nil?
# If there's no cache, then there's nothing to complain about
end

def delete_matched(matcher, options) #:nodoc:
Expand All @@ -381,7 +381,7 @@ def delete_matched(matcher, options) #:nodoc:
begin
File.delete(f)
rescue Object => e
Base.logger.error "Couldn't expire cache: #{f} (#{e.message})" unless Base.logger.nil?
# If there's no cache, then there's nothing to complain about
end
end
end
Expand Down

0 comments on commit 0223565

Please sign in to comment.