fix index sequence