Sha256: 0860fae9f19c1bcaeeab622330770fff4164da796709044cc9589394bd149784

Contents?: true

Size: 278 Bytes

Versions: 3

Compression:

Stored size: 278 Bytes

Contents

module Cachers
  module Concern
    extend ActiveSupport::Concern

    included do
      after_commit :cache, on: :create
      after_commit :recache, on: :update
      after_commit :uncache, on: :destroy
    end

    delegate :cache, :recache, :uncache, to: :cacher

  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
cachers-4.0.0.0 lib/cachers/concern.rb
cachers-0.1.1 lib/cachers/concern.rb
cachers-0.0.1 lib/cachers/concern.rb