Module: Catche::Expire::Pages
- Defined in:
- lib/catche/expire/pages.rb
Class Method Summary collapse
-
.expire!(*paths) ⇒ Object
Expires cache by deleting the associated files Uses the same flow as defined in ‘expire_page` in ActionController.
Class Method Details
.expire!(*paths) ⇒ Object
11 12 13 14 15 16 |
# File 'lib/catche/expire/pages.rb', line 11 def expire!(*paths) paths.each do |path| File.delete(path) if File.exist?(path) File.delete(path + '.gz') if File.exist?(path + '.gz') end end |