Skip to content

Commit

Permalink
feat(go): verify arguments in admin season-stats command
Browse files Browse the repository at this point in the history
  • Loading branch information
MikaelVallenet committed Apr 5, 2023
1 parent 6503eec commit 4937ffe
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions go/cmd/pathwar/admin.go
Original file line number Diff line number Diff line change
Expand Up @@ -805,6 +805,15 @@ func adminSeasonStats() *ffcli.Command {
return err
}

if format != "csv" && format != "json" {
return flag.ErrHelp
}

_, err := httpClientFromEnv(ctx)
if err != nil {
return errcode.TODO.Wrap(err)
}

return flag.ErrHelp
},
}
Expand Down

0 comments on commit 4937ffe

Please sign in to comment.