cleaning up the index pages