renamed index to index2