protected function makePassengerIfNeeded()
    {
        if (count($this->passengerData[0]->travellerInformation->passenger) < 1) {
            $this->passengerData[0]->travellerInformation->passenger[0] = new Passenger(null, null);
        }
    }
protected function makePassengerIfNeeded()
    {
        if (count($this->passengerData[0]->travellerInformation->passenger) < 1) {
            $this->passengerData[0]->travellerInformation->passenger[0] = new Passenger(null, null);
        }
    }
protected function makePassengerIfNeeded ( ) { if ( count ( $ this -> passengerData [ 0 ] -> travellerInformation -> passenger ) < 1 ) { $ this -> passengerData [ 0 ] -> travellerInformation -> passenger [ 0 ] = new Passenger ( null , null ) ; } }
If there is no passenger node at
$travellerInfo->passengerData[0]->travellerInformation->passenger[0]
create one
If there is no passenger node at $travellerInfo - > passengerData [ 0 ] - > travellerInformation - > passenger [ 0 ] create one