fix: RequestManager getting stuck on global ratelimit

fixes #2550
This commit is contained in:
Lewdcario
2018-05-13 14:17:26 -05:00
parent a732402c95
commit 75747f5b18
3 changed files with 30 additions and 23 deletions

View File

@@ -7,10 +7,12 @@ module.exports = function sequential() {
this.handle();
})
.catch(({ timeout }) => {
this.client.setTimeout(() => {
this.reset();
this.busy = false;
this.handle();
}, timeout);
if (timeout) {
this.client.setTimeout(() => {
this.reset();
this.busy = false;
this.handle();
}, timeout);
}
});
};