File: active_record.rb

package info (click to toggle)
ruby-paper-trail 12.0.0-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 1,200 kB
  • sloc: ruby: 6,743; makefile: 6
file content (12 lines) | stat: -rw-r--r-- 481 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
# frozen_string_literal: true

# Either ActiveRecord has already been loaded by the Lazy Load Hook in our
# Railtie, or else we load it now.
require "active_record"
::PaperTrail::Compatibility.check_activerecord(::ActiveRecord.gem_version)

# Now we can load the parts of PT that depend on AR.
require "paper_trail/has_paper_trail"
require "paper_trail/reifier"
require "paper_trail/frameworks/active_record/models/paper_trail/version"
ActiveRecord::Base.include PaperTrail::Model