Fix index ordering.