Cleanup of stats index delete code.