enabling auto flush