Fixed regex undefined

This commit is contained in:
PeekabooSteam
2023-11-16 11:16:54 +00:00
parent 9ef6efa3e0
commit 0421f6b8fe
2 changed files with 1 additions and 2 deletions

View File

@@ -34,7 +34,7 @@ export class UnitDataFileExport extends UnitDataFile {
const data:any = {};
const categories:string[] = [];
const coalitions:string[] = [];
const unitCanBeExported = (unit:Unit) => ["GroundUnit", "NavyUnit"].includes(unit.getCategory());
const unitCanBeExported = (unit:Unit) => !["Aircraft", "Helicopter"].includes(unit.getCategory());
units.filter((unit:Unit) => unit.getAlive() && unitCanBeExported(unit)).forEach((unit:Unit) => {
const category = unit.getCategoryLabel();