Kindof a hack, but it fixes the index problem