From e4c9aff1177e02d1f4fd1a4d5483aca59c3ffcb8 Mon Sep 17 00:00:00 2001 From: Jeff Colombo Date: Sun, 20 Jan 2019 20:22:09 -0500 Subject: [PATCH] fix double adding stats bug --- generatePokemonData.ts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/generatePokemonData.ts b/generatePokemonData.ts index 07a6fd3..a6c803a 100644 --- a/generatePokemonData.ts +++ b/generatePokemonData.ts @@ -170,11 +170,10 @@ Pokemon.forEach((mon) => { } return 0; }); - pokemon.pvp[league].push(...combinedStatsDistribution[league][combinedStats]); } }); - fs.mkdir(outPath, {recursive: true}, () => { + fs.mkdir(outPath, { recursive: true }, () => { fs.writeFile(outPath + mon.id + '.json', JSON.stringify(pokemon), (err) => { if (err) { /* tslint:disable-next-line:no-console */ @@ -202,7 +201,7 @@ familyOrder.forEach((familyId) => { }); }); -fs.mkdir(outPath, {recursive: true}, () => { +fs.mkdir(outPath, { recursive: true }, () => { fs.writeFile(outPath + 'order.json', JSON.stringify(pokemonOrder), (err) => { if (err) { /* tslint:disable-next-line:no-console */