Skip to content

Commit 2ebc266

Browse files
committed
fix code-style issues and ratelimit config
1 parent 16207b4 commit 2ebc266

1 file changed

Lines changed: 4 additions & 5 deletions

File tree

src/http/HTTP.ts

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,7 @@ import { FortniteAPIResponseData } from './httpStructs';
1212
class HTTP {
1313
public client: Client;
1414
public axios: AxiosInstance;
15-
public statsAxios : RateLimitedAxiosInstance;
16-
15+
public statsAxios: RateLimitedAxiosInstance;
1716
constructor(client: Client) {
1817
this.client = client;
1918

@@ -28,9 +27,9 @@ class HTTP {
2827
Authorization: this.client.config.apiKey,
2928
} : {},
3029
},
31-
3230
});
33-
this.statsAxios = rateLimit(this.axios, { maxRequests: 3, perMilliseconds: 1100, maxRPS: 3 });
31+
32+
this.statsAxios = rateLimit(this.axios, { maxRequests: 3, perMilliseconds: 1100 });
3433
}
3534

3635
public async fetch(url: string, params?: any): Promise<FortniteAPIResponseData> {
@@ -70,7 +69,7 @@ class HTTP {
7069
throw e;
7170
}
7271
}
73-
72+
7473
public async fetchStats(url: string, params?: any): Promise<FortniteAPIResponseData> {
7574
try {
7675
const response = await this.statsAxios.get(url, {

0 commit comments

Comments
 (0)