Fixed Inv bug