1
0
Fork 0
mirror of https://github.com/paper-trail-gem/paper_trail.git synced 2022-11-09 11:33:19 -05:00
paper-trail-gem--paper_trail/lib/paper_trail/version_association_concern.rb
2016-04-09 01:08:34 -04:00

17 lines
455 B
Ruby

require "active_support/concern"
module PaperTrail
# Functionality for `PaperTrail::VersionAssociation`. Exists in a module
# for the same reasons outlined in version_concern.rb.
module VersionAssociationConcern
extend ::ActiveSupport::Concern
included do
belongs_to :version
if PaperTrail.active_record_protected_attributes?
attr_accessible :version_id, :foreign_key_name, :foreign_key_id
end
end
end
end