enable eslint rule curly: multi-line

https://eslint.org/docs/latest/rules/curly#multi-line
This commit is contained in:
Scott Anderson
2025-08-07 21:37:57 -04:00
parent d1b5c80ccd
commit 91974aa906
9 changed files with 39 additions and 19 deletions
+8 -4
View File
@@ -124,25 +124,29 @@ export class WarshipExecution implements Execution {
if (
unitA.type() === UnitType.TransportShip &&
unitB.type() !== UnitType.TransportShip
)
) {
return -1;
}
if (
unitA.type() !== UnitType.TransportShip &&
unitB.type() === UnitType.TransportShip
)
) {
return 1;
}
// Then prioritize Warships.
if (
unitA.type() === UnitType.Warship &&
unitB.type() !== UnitType.Warship
)
) {
return -1;
}
if (
unitA.type() !== UnitType.Warship &&
unitB.type() === UnitType.Warship
)
) {
return 1;
}
// If both are the same type, sort by distance (lower `distSquared` means closer)
return distA - distB;