Fix issue in core data related to a bad type for id