adding sync for messages, not working right
debugging message sync