diff options
author | Flam3rboy <34555296+Flam3rboy@users.noreply.github.com> | 2021-09-13 17:59:21 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-09-13 17:59:21 +0200 |
commit | 924f3cc39a270065fab917f113bcd7eca514c836 (patch) | |
tree | 89367fdebb4f2592b5183047b04ec4259daeaaf3 /util | |
parent | :bug: fix In() query (diff) | |
parent | Delete attachments of deleted messages, fix #273 (diff) | |
download | server-924f3cc39a270065fab917f113bcd7eca514c836.tar.xz |
Merge pull request #355 from AlTech98/attachments
Attachments fixes
Diffstat (limited to 'util')
-rw-r--r-- | util/src/entities/Message.ts | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/util/src/entities/Message.ts b/util/src/entities/Message.ts index f4c7fdc7..506db71a 100644 --- a/util/src/entities/Message.ts +++ b/util/src/entities/Message.ts @@ -128,7 +128,7 @@ export class Message extends BaseClass { sticker_items?: Sticker[]; @JoinColumn({ name: "attachment_ids" }) - @OneToMany(() => Attachment, (attachment: Attachment) => attachment.message) + @OneToMany(() => Attachment, (attachment: Attachment) => attachment.message, { cascade: true }) attachments?: Attachment[]; @Column({ type: "simple-json" }) |