Add delete action for upload files, refactoring controllers