Changed class format to BaseClass

This commit is contained in:
ION606
2023-04-07 20:12:16 -04:00
parent e6b32cc115
commit b6d35c8e55
11 changed files with 97 additions and 227 deletions
+2 -2
View File
@@ -148,7 +148,7 @@ export class Client extends EventEmitter {
if (!isUser) token = "Bot " + token;
this.axiosCustom = axios.create({
baseURL: "https://discord.com/api/",
headers: { Authorization: this.#token }
headers: { Authorization: token }
});
return new Promise((resolve, reject) => {
@@ -180,7 +180,7 @@ export class Client extends EventEmitter {
this.ws.on('message', async (msg) => {
const data = JSON.parse(msg.toString());
const response = await handleResponses(data, token, this.id);
const response = await handleResponses(data, token, this);
if (response.op == 10) { return this.#startHeartBeat(response.heartBeat, token); }