refactored deleteEntity() in commitmentEntityManager a bit