protected function checkLanguages($languageArguments)
    {
        $languages = $this->site->getStandardLanguages();
        $language_codes = array_keys($languages);
        $buildLanguages = [];
        foreach ($languageArguments as $language) {
            if (array_search($language, $language_codes)) {
                $buildLanguages[$language] = $languages[$language];
            } elseif ($language_code = array_search($language, $languages)) {
                $buildLanguages[$language_code] = $language;
            } else {
                $this->addMissingLanguage($language);
            }
        }
        return $buildLanguages;
    }
protected function checkLanguages($languageArguments)
    {
        $languages = $this->site->getStandardLanguages();
        $language_codes = array_keys($languages);
        $buildLanguages = [];
        foreach ($languageArguments as $language) {
            if (array_search($language, $language_codes)) {
                $buildLanguages[$language] = $languages[$language];
            } elseif ($language_code = array_search($language, $languages)) {
                $buildLanguages[$language_code] = $language;
            } else {
                $this->addMissingLanguage($language);
            }
        }
        return $buildLanguages;
    }
protected function checkLanguages ( $ languageArguments ) { $ languages = $ this -> site -> getStandardLanguages ( ) ; $ language_codes = array_keys ( $ languages ) ; $ buildLanguages = [ ] ; foreach ( $ languageArguments as $ language ) { if ( array_search ( $ language , $ language_codes ) ) { $ buildLanguages [ $ language ] = $ languages [ $ language ] ; } elseif ( $ language_code = array_search ( $ language , $ languages ) ) { $ buildLanguages [ $ language_code ] = $ language ; } else { $ this -> addMissingLanguage ( $ language ) ; } } return $ buildLanguages ; }
Checks the existance of the languages in the system.

@param array $languageArguments
List of language arguments.

@return array
List of available languages.
Checks the existance of the languages in the system .