Open stahor opened 3 years ago
https://github.com/westonganger/paper_trail-association_tracking/blob/015422c567f75b6b8de708312b5dc9b7da143437/lib/paper_trail_association_tracking/reifiers/has_many.rb#L104 The line above leads to errors as soon as you customize the version association name. It tries to join ::PaperTrail::VersionAssociation to some a wrong association (e.g. my_custom_version) while it must be just joins(:version) https://github.com/westonganger/paper_trail-association_tracking/blob/015422c567f75b6b8de708312b5dc9b7da143437/lib/paper_trail_association_tracking/version_association_concern.rb#L10
::PaperTrail::VersionAssociation
joins(:version)
Ok would you consider creating a PR with test cases for this?
https://github.com/westonganger/paper_trail-association_tracking/blob/015422c567f75b6b8de708312b5dc9b7da143437/lib/paper_trail_association_tracking/reifiers/has_many.rb#L104 The line above leads to errors as soon as you customize the version association name. It tries to join
::PaperTrail::VersionAssociation
to some a wrong association (e.g. my_custom_version) while it must be justjoins(:version)
https://github.com/westonganger/paper_trail-association_tracking/blob/015422c567f75b6b8de708312b5dc9b7da143437/lib/paper_trail_association_tracking/version_association_concern.rb#L10