mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-10-24 20:19:49 +02:00
feat: put other in end
This commit is contained in:
1 parent
939acad30c
commit
059358cff4
1 file changed
+6
-5
@@ -183,11 +183,12 @@ export const TIER_ROMAN_NUMERALS: Record<Tier, string> = {
|
|||||||
};
|
};
|
||||||
|
|
||||||
export const NATIONS = tanksDefinitionsArray.then((tanks) => {
|
export const NATIONS = tanksDefinitionsArray.then((tanks) => {
|
||||||
const nationsObject: Record<string, true> = {};
|
const nations = Array.from(
|
||||||
|
new Set<string>(Object.values(tanks).map((tank) => tank.nation)),
|
||||||
|
);
|
||||||
|
|
||||||
tanks.forEach(({ nation }) => {
|
nations.splice(nations.indexOf('other'), 1);
|
||||||
nationsObject[nation] = true;
|
nations.push('other');
|
||||||
});
|
|
||||||
|
|
||||||
return Object.keys(nationsObject);
|
return nations;
|
||||||
});
|
});
|
||||||
Reference in new issue
Block a user