prepare for next iteration