updated the index