Skip to content

Commit

Permalink
RPS fix
Browse files Browse the repository at this point in the history
  • Loading branch information
dimuska139 committed Nov 9, 2020
1 parent d62da3e commit 75aa09b
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions client.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ import (
"net/http"
"net/url"
"strings"
"time"
)

const apiBaseUrl = "https://api.rawg.io/api"
Expand Down Expand Up @@ -44,7 +43,7 @@ func NewClient(client *http.Client, config *Config) *Client {
return &Client{
client: client,
config: config,
rateLimiter: rate.NewLimiter(rate.Every(1*time.Second), rps),
rateLimiter: rate.NewLimiter(rate.Limit(rps), rps),
}
}

Expand Down

0 comments on commit 75aa09b

Please sign in to comment.