forked from pothtonswer/discordmuffin
Fix invalid RateLimit event type
This commit is contained in:
parent
8d6815dde7
commit
e2c5d80fa6
1 changed files with 1 additions and 1 deletions
|
@ -155,7 +155,7 @@ func (s *Session) RequestWithLockedBucket(method, urlStr, contentType string, b
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
s.log(LogInformational, "Rate Limiting %s, retry in %d", urlStr, rl.RetryAfter)
|
s.log(LogInformational, "Rate Limiting %s, retry in %d", urlStr, rl.RetryAfter)
|
||||||
s.handleEvent(rateLimitEventType, RateLimit{TooManyRequests: &rl, URL: urlStr})
|
s.handleEvent(rateLimitEventType, &RateLimit{TooManyRequests: &rl, URL: urlStr})
|
||||||
|
|
||||||
time.Sleep(rl.RetryAfter * time.Millisecond)
|
time.Sleep(rl.RetryAfter * time.Millisecond)
|
||||||
// we can make the above smarter
|
// we can make the above smarter
|
||||||
|
|
Loading…
Reference in a new issue