simplify setting teamId

This commit is contained in:
filifa 2024-07-28 22:47:11 -05:00
parent e1e0225612
commit 68b3268054
1 changed files with 2 additions and 4 deletions

View File

@ -30,10 +30,8 @@ var team teamFlag
var sport = sportFlag("mlb") var sport = sportFlag("mlb")
func schedule(cmd *cobra.Command, args []string) { func schedule(cmd *cobra.Command, args []string) {
var teamId string teamId := ""
if team == "" { if team != "" {
teamId = string(team)
} else {
teamId = strconv.Itoa(int(teamIDs[string(team)])) teamId = strconv.Itoa(int(teamIDs[string(team)]))
} }