mirror of
https://github.com/danbulant/discord.js
synced 2026-07-09 13:10:42 +00:00
docs/typings: RateLimitInfo#limit instead of requestLimit (#3132)
* fix doc for ratelimit data, fixes #3131 * adapt typings * typings: unindent #region comments
This commit is contained in:
parent
6e761eb030
commit
be2f78851f
2 changed files with 4 additions and 4 deletions
|
|
@ -95,10 +95,10 @@ class SequentialRequestHandler extends RequestHandler {
|
||||||
* Emitted when the client hits a rate limit while making a request
|
* Emitted when the client hits a rate limit while making a request
|
||||||
* @event Client#rateLimit
|
* @event Client#rateLimit
|
||||||
* @param {Object} rateLimitInfo Object containing the rate limit info
|
* @param {Object} rateLimitInfo Object containing the rate limit info
|
||||||
* @param {number} rateLimitInfo.requestLimit Number of requests that can be made to this endpoint
|
* @param {number} rateLimitInfo.limit Number of requests that can be made to this endpoint
|
||||||
* @param {number} rateLimitInfo.timeDifference Delta-T in ms between your system and Discord servers
|
* @param {number} rateLimitInfo.timeDifference Delta-T in ms between your system and Discord servers
|
||||||
* @param {string} rateLimitInfo.method HTTP method used for request that triggered this event
|
|
||||||
* @param {string} rateLimitInfo.path Path used for request that triggered this event
|
* @param {string} rateLimitInfo.path Path used for request that triggered this event
|
||||||
|
* @param {string} rateLimitInfo.method HTTP method used for request that triggered this event
|
||||||
*/
|
*/
|
||||||
this.client.emit(RATE_LIMIT, {
|
this.client.emit(RATE_LIMIT, {
|
||||||
limit: this.requestLimit,
|
limit: this.requestLimit,
|
||||||
|
|
|
||||||
4
typings/index.d.ts
vendored
4
typings/index.d.ts
vendored
|
|
@ -2037,7 +2037,7 @@ declare module 'discord.js' {
|
||||||
|
|
||||||
type ClientPresenceStatus = 'online' | 'idle' | 'dnd';
|
type ClientPresenceStatus = 'online' | 'idle' | 'dnd';
|
||||||
|
|
||||||
type PresenceStatus = ClientPresenceStatus | 'invisible' ;
|
type PresenceStatus = ClientPresenceStatus | 'invisible';
|
||||||
type PresenceStatusData = ClientPresenceStatus | 'offline';
|
type PresenceStatusData = ClientPresenceStatus | 'offline';
|
||||||
|
|
||||||
type ClientPresenceStatusData = {
|
type ClientPresenceStatusData = {
|
||||||
|
|
@ -2047,7 +2047,7 @@ declare module 'discord.js' {
|
||||||
};
|
};
|
||||||
|
|
||||||
type RateLimitInfo = {
|
type RateLimitInfo = {
|
||||||
requestLimit: number;
|
limit: number;
|
||||||
timeDifference: number;
|
timeDifference: number;
|
||||||
method: string;
|
method: string;
|
||||||
path: string;
|
path: string;
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue