add code to flush