mirror of
https://github.com/kwsch/PKHeX.git
synced 2026-08-24 18:56:58 -05:00
Update gender check
showdownset now no longer leaks nulls
This commit is contained in:
@@ -219,7 +219,7 @@ public static void SetMaximumPPCurrent(this PKM pk, int[] Moves = null)
|
||||
/// <param name="gender">Desired <see cref="PKM.Gender"/> value to set.</param>
|
||||
public static void SetGender(this PKM pk, string gender)
|
||||
{
|
||||
int g = gender == null
|
||||
int g = string.IsNullOrEmpty(gender)
|
||||
? pk.GetSaneGender()
|
||||
: PKX.GetGenderFromString(gender);
|
||||
pk.SetGender(g);
|
||||
|
||||
Reference in New Issue
Block a user