can't you just use `existingIDs.indexOf` here?