diff --git a/src/gateway/Server.ts b/src/gateway/Server.ts
index 7fea1a27..c6419cfa 100644
--- a/src/gateway/Server.ts
+++ b/src/gateway/Server.ts
@@ -38,9 +38,9 @@ export class Server {
if (server) this.server = server;
else {
- const elu = [1, 5, 15].map((x) => performance.eventLoopUtilization());
- const eluP = [1, 5, 15].map((x) => performance.eventLoopUtilization());
- const cpu = [1, 5, 15].map((x) => process.cpuUsage());
+ const elu = [1, 5, 15].map(() => performance.eventLoopUtilization());
+ const eluP = [1, 5, 15].map(() => performance.eventLoopUtilization());
+ const cpu = [1, 5, 15].map(() => process.cpuUsage());
let sec = 0;
setInterval(() => {
sec += 1;
diff --git a/src/gateway/opcodes/Identify.ts b/src/gateway/opcodes/Identify.ts
index 65c54ae0..7dd21658 100644
--- a/src/gateway/opcodes/Identify.ts
+++ b/src/gateway/opcodes/Identify.ts
@@ -64,11 +64,6 @@ import { ChannelType, DefaultUserGuildSettings, DMChannel, IdentifySchema, Priva
// TODO: user sharding
// TODO: check privileged intents, if defined in the config
-function logAuth(message: string) {
- if (process.env.LOG_AUTH != "true") return;
- console.log(`[Gateway/Auth] ${message}`);
-}
-
export async function onIdentify(this: WebSocket, data: Payload) {
const totalSw = Stopwatch.startNew();
const taskSw = Stopwatch.startNew();
diff --git a/src/gateway/opcodes/LazyRequest.ts b/src/gateway/opcodes/LazyRequest.ts
index 0e63a7d2..cb465cf0 100644
--- a/src/gateway/opcodes/LazyRequest.ts
+++ b/src/gateway/opcodes/LazyRequest.ts
@@ -158,6 +158,7 @@ export async function onLazyRequest(this: WebSocket, { d }: Payload) {
const startTime = Date.now();
// TODO: check data
check.call(this, LazyRequestSchema, d);
+ // noinspection JSUnusedLocalSymbols - TODO: implement typing/activities subscriptions
const { guild_id, typing, channels, activities, members } = d as LazyRequestSchema;
if (members) {
diff --git a/src/gateway/opcodes/StreamDelete.ts b/src/gateway/opcodes/StreamDelete.ts
index c5d8bec3..6135e1f3 100644
--- a/src/gateway/opcodes/StreamDelete.ts
+++ b/src/gateway/opcodes/StreamDelete.ts
@@ -21,6 +21,7 @@ export async function onStreamDelete(this: WebSocket, data: Payload) {
return this.close(4000, "Invalid stream key");
}
+ // noinspection JSUnusedLocalSymbols - TODO: what is type here?
const { userId, channelId, guildId, type } = parsedKey;
// when a user selects to stop watching another user stream, this event gets triggered
diff --git a/src/gateway/util/Utils.ts b/src/gateway/util/Utils.ts
index ec0f411c..1ca45ee4 100644
--- a/src/gateway/util/Utils.ts
+++ b/src/gateway/util/Utils.ts
@@ -58,7 +58,7 @@ export async function cleanupOnStartup(): Promise<void> {
console.log("[Gateway] Starting async voice state wipe...");
VoiceState.clear()
- .then((e) => console.log("[Gateway] Successfully cleaned voice states"))
+ .then(() => console.log("[Gateway] Successfully cleaned voice states"))
.catch((e) => console.error("[Gateway] Error cleaning voice states on startup:", e));
}
|