Changes according to Eslint

This commit is contained in:
Daniël van Noord
2021-03-16 09:32:50 +01:00
parent 26d8e75935
commit a65af049b6
63 changed files with 314 additions and 295 deletions

View File

@@ -42,11 +42,11 @@ export function CacheStatsCookies() {
CacheEdifice = 0;
let max = 0;
let n = 0;
for (const i of Object.keys(Game.Objects)) {
Object.keys(Game.Objects).forEach((i) => {
if (Game.Objects[i].amount > max) max = Game.Objects[i].amount;
if (Game.Objects[i].amount > 0) n++;
}
for (const i of Object.keys(Game.Objects)) {
if (Game.Objects[i].amount > 0) n += 1;
});
Object.keys(Game.Objects).forEach((i) => {
if (
(Game.Objects[i].amount < max || n === 1) &&
Game.Objects[i].amount < 400 &&
@@ -55,7 +55,7 @@ export function CacheStatsCookies() {
CacheEdifice = Game.Objects[i].price * 2;
CacheEdificeBuilding = i;
}
}
});
}
/**