Deprecate all the things

This commit is contained in:
Amish Shah
2017-04-29 21:09:53 +01:00
parent b0a3528411
commit c40252381b
5 changed files with 41 additions and 2 deletions

View File

@@ -65,7 +65,7 @@ class SequentialRequestHandler extends RequestHandler {
}, Number(res.headers['retry-after']) + this.restManager.client.options.restTimeOffset);
if (res.headers['x-ratelimit-global']) this.globalLimit = true;
} else {
item.reject(err.status === 400 ? new DiscordAPIError(res.body) : err);
item.reject(err.status >= 400 && err.status < 500 ? new DiscordAPIError(res.body) : err);
resolve(err);
}
} else {