smogon / pokemon-showdown-client

The client for Pokémon Showdown
http://pokemonshowdown.com
GNU Affero General Public License v3.0
562 stars 789 forks source link

Don't guess spreads when there are empty moves #2267

Closed DaWoblefet closed 3 months ago

DaWoblefet commented 3 months ago

Currently, when the teambuilder supplies a guessed spread, it will consider moves with the empty string for its check. This prevents the teambuilder from guessing spreads after the user only puts in 3 moves.

I'm not sure if the correct fix is here or in some way deleting the empty string move from set.moves altogether at some other point.

pyuk-bot commented 3 months ago

I think this is a better spot because it doesn’t rely on trusting the teambuilder to provide sanitized input.