Sha256: a893ae102570f456c49fa3b3eb60e5029a166dfc63321694e0d9bddef7c5fbe3

Contents?: true

Size: 410 Bytes

Versions: 2

Compression:

Stored size: 410 Bytes

Contents

module Cachers
  module Extensions
    module ActiveRecord
      module Base
        extend ActiveSupport::Concern

        module ClassMethods

          def inherited(subclass)
            super
            if File.exist?("#{Rails.root}/app/cachers/#{subclass.name.underscore}_cacher.rb")
              subclass.include Cachers::Concern
            end
          end

        end
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
cachers-5.1.1 lib/cachers/extensions/active_record/base.rb
cachers-4.1.0.0 lib/cachers/extensions/active_record/base.rb