Skip to content

2.7.2 — Fix bulk delete, force delete and restore in generated controllers

Choose a tag to compare

@dejwCake dejwCake released this 04 Nov 20:58
· 2 commits to main since this release

Changes generated output only: regenerate controllers to pick up the fixes. Existing code is not touched.

Fixed

  • Bulk delete, force delete and restore no longer stop half-way: the ->each() callbacks returned the model's delete() / forceDelete() / restore() result, and a false return ended the loop. They now return nothing.
  • User template: destroy() runs in a transaction, and bulkDestroy() deletes the models one by one instead of with a query-level delete, so model events and soft deletes apply.