Module: CaChing::WriteThrough::InstanceMethods

Defined in:
lib/ca_ching/write_through.rb

Instance Method Summary collapse

Instance Method Details

#save_with_cacheObject



9
10
11
12
13
14
# File 'lib/ca_ching/write_through.rb', line 9

def save_with_cache(*)
  return save_without_cache if CaChing.cache.nil? || CaChing.disabled?
  
  CaChing.cache.update(self)
  save_without_cache
end