From 853fd51283bfc68afff769e7e6e45f53343fec52 Mon Sep 17 00:00:00 2001 From: Guangcong Luo Date: Mon, 3 Oct 2016 23:43:36 -0400 Subject: [PATCH] Battles: Fix crash relating to getPokemon _Some_ past gens apparently don't specify slots for active pokemon sometimes... --- js/battle.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/battle.js b/js/battle.js index fc5efeefb..515abf0b6 100644 --- a/js/battle.js +++ b/js/battle.js @@ -5811,7 +5811,7 @@ var Battle = (function () { if (!details) { if (siden < 0) return null; if (this.sides[siden].active[slot]) return this.sides[siden].active[slot]; - isInactive = true; + if (slot >= 0) isInactive = true; } var searchid = '';