renames index to index