From f671eda02980ff299416a86c23d737eaff325d71 Mon Sep 17 00:00:00 2001 From: Flashfyre Date: Thu, 7 Dec 2023 18:20:41 -0500 Subject: [PATCH] Fix crash related to mega evolutions --- src/data/pokemon-species.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/data/pokemon-species.ts b/src/data/pokemon-species.ts index f45858b8d..cee11f8f0 100644 --- a/src/data/pokemon-species.ts +++ b/src/data/pokemon-species.ts @@ -313,7 +313,7 @@ export default class PokemonSpecies extends PokemonSpeciesForm { } } - if (!allowEvolving || !pokemonEvolutions.hasOwnProperty(this.speciesId)) + if (!allowEvolving || !pokemonEvolutions.hasOwnProperty(this.speciesId) || pokemonEvolutions[this.speciesId].filter(e => !e.evoFormKey || e.evoFormKey.indexOf(SpeciesFormKey.MEGA) === -1)) return this.speciesId; const evolutions = pokemonEvolutions[this.speciesId];