Module: PagesCore::StaticCacheController::ClassMethods
- Defined in:
- app/controllers/concerns/pages_core/static_cache_controller.rb
Instance Method Summary collapse
- #static_cache(*actions, permanent: false) ⇒ Object (also: #caches_page)
Instance Method Details
#static_cache(*actions, permanent: false) ⇒ Object Also known as: caches_page
8 9 10 11 12 13 14 15 16 |
# File 'app/controllers/concerns/pages_core/static_cache_controller.rb', line 8 def static_cache(*actions, permanent: false) return unless perform_caching if permanent after_action :cache_static_page_permanently, only: actions else after_action :cache_static_page, only: actions end end |