added a thread to the chat client to allow for constant polling of the server