fixes for save, so we can retrieve _ids