Update the delete function for each model