Module: ActionPolicy::Policy::Cache::InstanceMethods

Defined in:
lib/action_policy/policy/cache.rb

Overview

:nodoc:

Instance Method Summary collapse

Instance Method Details

#apply(rule) ⇒ Object



46
47
48
49
50
51
# File 'lib/action_policy/policy/cache.rb', line 46

def apply(rule)
  return super if ActionPolicy.cache_store.nil? ||
                  !self.class.cached_rules.key?(rule)

  apply_with_cache(rule) { super }
end