mirror of
https://github.com/go-gitea/gitea
synced 2024-12-25 01:54:26 +00:00
Co-authored-by: Lauris BH <lauris@nix.lv>
This commit is contained in:
parent
b228a0aa44
commit
729fa06468
@ -132,6 +132,11 @@ func (g *GithubDownloaderV3) sleep() {
|
||||
func (g *GithubDownloaderV3) RefreshRate() error {
|
||||
rates, _, err := g.client.RateLimits(g.ctx)
|
||||
if err != nil {
|
||||
// if rate limit is not enabled, ignore it
|
||||
if strings.Contains(err.Error(), "404") {
|
||||
g.rate = nil
|
||||
return nil
|
||||
}
|
||||
return err
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user