cleaned up delete method