Add "delete" function to MediaEntry
|Reported by:||spaetz||Owned by:|
Just working on issue 302 (Delete your own account), noticing that deleting a MediaEntry and all related Comments / Files / Tags / Collections has to be done manually e.g. in user_pages/views.py:media_confirm_delete().
It would make sense to provide a "delete()" function for MediaEntry that did all this work centrally. It would simplify the view functions and put the internal implementation details into the db models where they belong. It would also enable me to easily delete all user's media from the delete_user_account function without having to manually duplicate the thing.