Is it possible to check the value of:
config.action_controller.perform_caching
...fr开发者_如何转开发om within ApplicationController?
I have some custom caching methods that should or shouldn't be called based on this value.
ActionController::Base.perform_caching
returns true or false depending on whether the caching is enabled.
As of Rails 3.x, you can use this:
Rails.configuration.action_controller.perform_caching
精彩评论