Refactored deleteModel