Refactor deletion