Skip to content

Commit

Permalink
Check for Weather.None
Browse files Browse the repository at this point in the history
  • Loading branch information
versx committed Jun 5, 2021
1 parent fb60b6e commit 1306e17
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Net/Models/PokemonData.cs
Original file line number Diff line number Diff line change
Expand Up @@ -486,7 +486,7 @@ private IReadOnlyDictionary<string, string> GetProperties(MessageProperties prop
var weather = Weather?.ToString();
var hasWeather = Weather.HasValue && Weather != WeatherCondition.None;
var isWeatherBoosted = pkmnInfo?.IsWeatherBoosted(Weather ?? WeatherCondition.None);
var weatherEmoji = (Weather ?? WeatherCondition.None).GetEmojiIcon("weather", false);
var weatherEmoji = Weather != WeatherCondition.None ? Weather.GetEmojiIcon("weather", false) : null;
var move1 = int.TryParse(FastMove, out var fastMoveId) ? Translator.Instance.GetMoveName(fastMoveId) : "Unknown";
var move2 = int.TryParse(ChargeMove, out var chargeMoveId) ? Translator.Instance.GetMoveName(chargeMoveId) : "Unknown";
var type1 = pkmnInfo?.Types?[0];
Expand Down

0 comments on commit 1306e17

Please sign in to comment.