Refactor with remove-entity