Reworking core data error handling