drawing not conenct to the server and saves the image properly