messages bug fix