src/Sulu/Component/Webspace/Loader/XmlFileLoader10.php
protected function validateDefaultLocalization($localizations)
    {
        $result = false;
        foreach ($localizations as $localization) {
            if ($localization->isDefault()) {
                if ($result) {
                    throw new InvalidDefaultLocalizationException();
                }
                $result = true;
            }
        }

        return $result;
    }
protected function validateDefaultLocalization($localizations)
    {
        $result = false;
        foreach ($localizations as $localization) {
            if ($localization->isDefault()) {
                if ($result) {
                    throw new InvalidDefaultLocalizationException();
                }
                $result = true;
            }
        }

        return $result;
    }
protected function validateDefaultLocalization ( $ localizations ) { $ result = false ; foreach ( $ localizations as $ localization ) { if ( $ localization -> isDefault ( ) ) { if ( $ result ) { throw new InvalidDefaultLocalizationException ( ) ; } $ result = true ; } } return $ result ; }
Returns true if there is one default localization.

@param $localizations

@return bool

@throws Exception\InvalidDefaultLocalizationException
Returns true if there is one default localization .