app/Statistics/Google/ChartDistribution.php
private function getIso3166Countries(): array
    {
        $countries = $this->country_service->getAllCountries();

        // Get the country names for each language
        $country_to_iso3166 = [];

        foreach (I18N::activeLocales() as $locale) {
            I18N::init($locale->languageTag());

            foreach ($this->country_service->iso3166() as $three => $two) {
                $country_to_iso3166[$three]             = $two;
                $country_to_iso3166[$countries[$three]] = $two;
            }
        }

        return $country_to_iso3166;
    }
private function getIso3166Countries(): array
    {
        $countries = $this->country_service->getAllCountries();

        // Get the country names for each language
        $country_to_iso3166 = [];

        foreach (I18N::activeLocales() as $locale) {
            I18N::init($locale->languageTag());

            foreach ($this->country_service->iso3166() as $three => $two) {
                $country_to_iso3166[$three]             = $two;
                $country_to_iso3166[$countries[$three]] = $two;
            }
        }

        return $country_to_iso3166;
    }
private function getIso3166Countries ( ) : array { $ countries = $ this -> country_service -> getAllCountries ( ) ; // Get the country names for each language $ country_to_iso3166 = [ ] ; foreach ( I18N :: activeLocales ( ) as $ locale ) { I18N :: init ( $ locale -> languageTag ( ) ) ; foreach ( $ this -> country_service -> iso3166 ( ) as $ three => $ two ) { $ country_to_iso3166 [ $ three ] = $ two ; $ country_to_iso3166 [ $ countries [ $ three ] ] = $ two ; } } return $ country_to_iso3166 ; }
Returns the country names for each language.

@return string[]
Returns the country names for each language .