fixed double flash message bug