diff --git a/Nhl.Api.Domain/Services/NhlTeamService.cs b/Nhl.Api.Domain/Services/NhlTeamService.cs index dd6cee1..e554858 100644 --- a/Nhl.Api.Domain/Services/NhlTeamService.cs +++ b/Nhl.Api.Domain/Services/NhlTeamService.cs @@ -262,7 +262,10 @@ public List GetTeamCodeIdentifierByTeamEnumerations(List teamE TeamNames.VegasGoldenKnights => TeamCodes.VegasGoldenKnights, TeamNames.WashingtonCapitals => TeamCodes.WashingtonCapitals, TeamNames.WinnipegJets => TeamCodes.WinnipegJets, - TeamNames.UtahHockeyClub => TeamCodes.UtahHockeyClub, - _ => throw new ArgumentException($"Unknown NHL team: {teamName}", nameof(teamName)), + public string? GetTeamCodeIdentifierByTeamName(string teamName) => teamName.ReplaceNonAsciiWithAscii() switch + { + TeamNames.UtahHockeyClub => TeamCodes.UtahHockeyClub, + _ => null, + }; }; }