Revert "Revert "fix index""

This reverts commit 249ae9bcf91d8b5eb712dac8488cf1810ea036ee.