Code style: All uppercase acronyms URL, ISRC, ID, HTTP

This commit is contained in:
Philipp Wolfer 2025-04-29 13:23:41 +02:00
parent 39b31fc664
commit d51c97c648
No known key found for this signature in database
GPG key ID: 8FDF744D4919943B
26 changed files with 137 additions and 137 deletions

View file

@ -40,7 +40,7 @@ const (
)
type Client struct {
HttpClient *resty.Client
HTTPClient *resty.Client
}
func NewClient(token oauth2.TokenSource) Client {
@ -55,7 +55,7 @@ func NewClient(token oauth2.TokenSource) Client {
ratelimit.EnableHTTPHeaderRateLimit(client, "Retry-After")
return Client{
HttpClient: client,
HTTPClient: client,
}
}
@ -69,7 +69,7 @@ func (c Client) RecentlyPlayedBefore(before time.Time, limit int) (RecentlyPlaye
func (c Client) recentlyPlayed(after *time.Time, before *time.Time, limit int) (result RecentlyPlayedResult, err error) {
const path = "/me/player/recently-played"
request := c.HttpClient.R().
request := c.HTTPClient.R().
SetQueryParam("limit", strconv.Itoa(limit)).
SetResult(&result)
if after != nil {
@ -87,7 +87,7 @@ func (c Client) recentlyPlayed(after *time.Time, before *time.Time, limit int) (
func (c Client) UserTracks(offset int, limit int) (result TracksResult, err error) {
const path = "/me/tracks"
response, err := c.HttpClient.R().
response, err := c.HTTPClient.R().
SetQueryParams(map[string]string{
"offset": strconv.Itoa(offset),
"limit": strconv.Itoa(limit),