summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/api/routes/channels/#channel_id/messages/#message_id/index.ts6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/api/routes/channels/#channel_id/messages/#message_id/index.ts b/src/api/routes/channels/#channel_id/messages/#message_id/index.ts
index 47faba73..6fccac30 100644
--- a/src/api/routes/channels/#channel_id/messages/#message_id/index.ts
+++ b/src/api/routes/channels/#channel_id/messages/#message_id/index.ts
@@ -82,7 +82,7 @@ router.patch(
 		});
 
 		await Promise.all([
-			new_message!.save(),
+			new_message.save(),
 			await emitEvent({
 				event: "MESSAGE_UPDATE",
 				channel_id,
@@ -90,9 +90,9 @@ router.patch(
 			} as MessageUpdateEvent),
 		]);
 
-		postHandleMessage(message);
+		postHandleMessage(new_message);
 
-		return res.json(message);
+		return res.json(new_message);
 	},
 );