Changed structure and added HTTPConnectionThread