renamed saveEntity to _save