fix inverse document