summary refs log tree commit diff
path: root/util/src/entities/Message.ts
diff options
context:
space:
mode:
authorFlam3rboy <34555296+Flam3rboy@users.noreply.github.com>2021-10-03 22:53:01 +0200
committerFlam3rboy <34555296+Flam3rboy@users.noreply.github.com>2021-10-03 22:53:01 +0200
commit2f7182ca3d8568aca24a73a6b6dc8da0f5fa6747 (patch)
tree928b1ccdec95a799afa1fb8b90716bac2c9a9d05 /util/src/entities/Message.ts
parentMerge pull request #411 from afeuerstein/master (diff)
downloadserver-2f7182ca3d8568aca24a73a6b6dc8da0f5fa6747.tar.xz
:bug: fix message reactions
Diffstat (limited to 'util/src/entities/Message.ts')
-rw-r--r--util/src/entities/Message.ts6
1 files changed, 2 insertions, 4 deletions
diff --git a/util/src/entities/Message.ts b/util/src/entities/Message.ts
index c4901693..04c3c7aa 100644
--- a/util/src/entities/Message.ts
+++ b/util/src/entities/Message.ts
@@ -74,9 +74,7 @@ export class Message extends BaseClass {
 	author_id: string;
 
 	@JoinColumn({ name: "author_id", referencedColumnName: "id" })
-	@ManyToOne(() => User, {
-		onDelete: "CASCADE",
-	})
+	@ManyToOne(() => User)
 	author?: User;
 
 	@Column({ nullable: true })
@@ -120,7 +118,7 @@ export class Message extends BaseClass {
 	mention_everyone?: boolean;
 
 	@JoinTable({ name: "message_user_mentions" })
-	@ManyToMany(() => User, { orphanedRowAction: "delete", onDelete: "CASCADE", cascade: true })
+	@ManyToMany(() => User)
 	mentions: User[];
 
 	@JoinTable({ name: "message_role_mentions" })