Rework modifications callback
We are firing the modification callbacks manually, which sucks when the change comes from a distant path (for instance, a folder gets removed, which triggers multiple media deletion)
Instead, let's leverage the sqlite hooks to fire the callbacks.
Pass entities IDs instead of the entities themselves to the modification callback (
- Remove manual events firing
- Plug modification callbacks to the sqlite hooks