#19 Send messages on the state changing