auditable
auditable copied to clipboard
Allow audits to be destroyed when parent model is destroyed
Is there any suggested workaround for this at the time?
An after_destroy on the parent to clean up the audits.
The fix maybe be as simple adding the :dependent => :delete to auditable in https://github.com/harleyttd/auditable/blob/master/lib/auditable/base.rb
Okay, I just took another look at the code an its actually already possible:
# Example
audit :title, version: true, dependent: :destroy