fixed flash message Bug