flash messages bug fixed