Moved messages and client handling functions in client.hs