From 6122374e4d97b2db040e8a98e4187dd0a0bccf9e Mon Sep 17 00:00:00 2001 From: TheArcaneBrony Date: Thu, 12 Jan 2023 13:46:36 +0100 Subject: Dev/post refactor fixes (#927) * Re-introduce outgoing message logging Signed-off-by: TheArcaneBrony * Websocket dumping * Sentry user count on API * Generate session ID upon opening websocket, fix gateway dumps * Async file io in src/gateway/events/Message.ts Signed-off-by: TheArcaneBrony * Async file io in src/util/util/Config.ts Signed-off-by: TheArcaneBrony * Make pre-commit hook executable Signed-off-by: TheArcaneBrony * Fixed sync file io in src/util/util/Config.ts Signed-off-by: TheArcaneBrony * Fixed missing await call in src/util/util/AutoUpdate.ts Signed-off-by: TheArcaneBrony * Add comment to src/gateway/events/Connection.ts Signed-off-by: TheArcaneBrony * Clean up gateway dumping code Signed-off-by: TheArcaneBrony Co-authored-by: Madeline <46743919+MaddyUnderStars@users.noreply.github.com> --- src/gateway/opcodes/Identify.ts | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'src/gateway/opcodes') diff --git a/src/gateway/opcodes/Identify.ts b/src/gateway/opcodes/Identify.ts index 29b17643..1c3cab28 100644 --- a/src/gateway/opcodes/Identify.ts +++ b/src/gateway/opcodes/Identify.ts @@ -55,9 +55,7 @@ export async function onIdentify(this: WebSocket, data: Payload) { return this.close(CLOSECODES.Authentication_failed); } this.user_id = decoded.id; - - const session_id = genSessionId(); - this.session_id = session_id; //Set the session of the WebSocket object + let session_id = this.session_id; const [user, read_states, members, recipients, session, application] = await Promise.all([ -- cgit 1.5.1