[Client] Fixed possible NullPointerException in disconnect handler