Finished chat client code