erp5_core: Fixes in Folder delete
This Merge Request has 4 commits, because semantically there are different topics
- First commit is a major cleanup, hopefully to allow a better review of this code
- Second and Third are some proposed functionality improvements
- Last commit adds a comment to pre-existing code, for which the behaviour may need more checking