Sha256: ac1fcd99342843569c8dcac23cfede19975356f31780e1678b14a60b8051518a

Contents?: true

Size: 580 Bytes

Versions: 1

Compression:

Stored size: 580 Bytes

Contents

require 'active_record'

module Audited
  class << self
    attr_accessor :ignored_attributes, :current_user_method
    attr_writer :audit_class

    def audit_class
      @audit_class ||= Audit
    end

    def store
      Thread.current[:audited_store] ||= {}
    end

    def config
      yield(self)
    end
  end

  @ignored_attributes = %w(lock_version created_at updated_at created_on updated_on)

  @current_user_method = :current_user
end

require 'audited/auditor'
require 'audited/audit'

::ActiveRecord::Base.send :include, Audited::Auditor

require 'audited/sweeper'

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
audited-4.6.0 lib/audited.rb