summary refs log tree commit diff
path: root/src/api/util
diff options
context:
space:
mode:
authorSamuel (Flam3rboy) <github@samuelscheit.com>2023-03-30 18:13:34 +0200
committerGitHub <noreply@github.com>2023-03-30 18:13:34 +0200
commit69ea71aa9e0bd2e5a98904a66fba0ad3745707cb (patch)
tree807384e6d19111a4e038113854bb28791814a8c7 /src/api/util
parentSPACEBAR (diff)
parentfeat: add DB_LOGGING env (diff)
downloadserver-69ea71aa9e0bd2e5a98904a66fba0ad3745707cb.tar.xz
Merge pull request #1008 from spacebarchat/dev/samuel
Diffstat (limited to 'src/api/util')
-rw-r--r--src/api/util/handlers/Message.ts2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/api/util/handlers/Message.ts b/src/api/util/handlers/Message.ts
index 65dbcdfe..8818904e 100644
--- a/src/api/util/handlers/Message.ts
+++ b/src/api/util/handlers/Message.ts
@@ -274,7 +274,7 @@ export async function sendMessage(opts: MessageOptions) {
 	const message = await handleMessage({ ...opts, timestamp: new Date() });
 
 	await Promise.all([
-		Message.insert(message),
+		message.save(),
 		emitEvent({
 			event: "MESSAGE_CREATE",
 			channel_id: opts.channel_id,