adding code for index rollback