Fix the bug in invertIndex. Data-Matching is still not functional