Check that the local id is valid, not the doc id.