Fix id mapping on sync updates