Closed ironpark closed 4 years ago
You are right, these missing options should be added. I would prefer an options struct as a vararg parameter, so existing usages of this method do not break. Like this:
func (c *MatchClient) List(accountID string, beginIndex, endIndex int, options... *MatchListOptions) (*Matchlist, error)
More options to "MatchClient"
/lol/match/v4/matchlists/by-account/{encryptedAccountId}
It has a total of 7 optional parameters. Since the season is DEPRECATED, in the remaining 6 cases, the current golio library supports only beginIndex and endIndex. The rest of the parameters are also useful depending on the situation, so I think it is better to support the rest. However, if all the parameters are supported, the following method is proposed as the function argument will be greatly enlarged..
Option Struct
Option Function
Builder