Commit c815a7cb authored by Tsvetelina Yordanova's avatar Tsvetelina Yordanova
Browse files

fix: #1137-order-countries

parent 8275a5d0
Loading
Loading
Loading
Loading
+6 −4
Original line number Diff line number Diff line
@@ -606,9 +606,11 @@ export function getCountryName(country: Country | null): CountryName | null {
	return countries[Country[country]] || null;
}

export const countriesIdsToNamesArray: Array<{
export const countriesIdsToNamesArray: {
	id: Country;
	name: CountryName;
}> = Object.keys(countries).map((abbr) => {
}[] = Object.keys(countries)
	.map((abbr) => {
		return { id: Country[abbr], name: getCountryName(+Country[abbr]) };
});
	})
	.sort((c1, c2) => c1.name.localeCompare(c2.name));