ActsAsParanoid / acts_as_paranoid

ActiveRecord plugin allowing you to hide and restore records without actually deleting them.
MIT License
1.47k stars 192 forks source link

after_commit on destroy only called for soft destroy on rails 6 #195

Open thijsnado opened 3 years ago

thijsnado commented 3 years ago

In rails 5.2, calling destroy twice on a paranoid record would run the after_commit on: :destroy method twice. We discovered when upgrading to rails 6 that this is no longer the case. Not sure if this is an issue but the expected behavior around those callbacks should be documented. The after_destroy callbacks however do run correctly.