Fix messages bug