Fixed reconnection bug.