From db828038bbe07bb4582494705bde3b5ab8563984 Mon Sep 17 00:00:00 2001 From: Kurt Date: Mon, 23 Nov 2015 19:29:36 -0800 Subject: [PATCH] Fix null comparison Thanks InfiniRien! --- pk3DS/Subforms/RSTE.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pk3DS/Subforms/RSTE.cs b/pk3DS/Subforms/RSTE.cs index 56f6519..45fb3eb 100644 --- a/pk3DS/Subforms/RSTE.cs +++ b/pk3DS/Subforms/RSTE.cs @@ -655,7 +655,7 @@ private void Randomize() int type = GetRandomType(i); bool mevo = rEnsureMEvo.Contains(i); bool typerand = rTypeTheme && !rGymE4Only || - (rTypeTheme && (rImportant[i].Contains("GYM") || rImportant[i].Contains("ELITE") || rImportant[i].Contains("CHAMPION"))); + (rTypeTheme && rImportant[i] != null && (rImportant[i].Contains("GYM") || rImportant[i].Contains("ELITE") || rImportant[i].Contains("CHAMPION"))); // Randomize Pokemon for (int p = 0; p < CB_numPokemon.SelectedIndex; p++)