summary refs log tree commit diff
path: root/src/util/entities/Attachment.ts
diff options
context:
space:
mode:
authorMadeline <46743919+MaddyUnderStars@users.noreply.github.com>2022-09-26 22:29:30 +1000
committerMadeline <46743919+MaddyUnderStars@users.noreply.github.com>2022-09-26 22:41:21 +1000
commit99ee7e9400f06e8718612d8b52d15215dc620774 (patch)
tree08de8c5d3985b9c2eaa419f5198f891ecd82d012 /src/util/entities/Attachment.ts
parentRemove the cdn storage location log (diff)
downloadserver-99ee7e9400f06e8718612d8b52d15215dc620774.tar.xz
Prettier
Diffstat (limited to 'src/util/entities/Attachment.ts')
-rw-r--r--src/util/entities/Attachment.ts19
1 files changed, 15 insertions, 4 deletions
diff --git a/src/util/entities/Attachment.ts b/src/util/entities/Attachment.ts

index 7b4b17eb..055b6f4b 100644 --- a/src/util/entities/Attachment.ts +++ b/src/util/entities/Attachment.ts
@@ -1,4 +1,11 @@ -import { BeforeRemove, Column, Entity, JoinColumn, ManyToOne, RelationId } from "typeorm"; +import { + BeforeRemove, + Column, + Entity, + JoinColumn, + ManyToOne, + RelationId, +} from "typeorm"; import { URL } from "url"; import { deleteFile } from "../util/cdn"; import { BaseClass } from "./BaseClass"; @@ -31,9 +38,13 @@ export class Attachment extends BaseClass { message_id: string; @JoinColumn({ name: "message_id" }) - @ManyToOne(() => require("./Message").Message, (message: import("./Message").Message) => message.attachments, { - onDelete: "CASCADE", - }) + @ManyToOne( + () => require("./Message").Message, + (message: import("./Message").Message) => message.attachments, + { + onDelete: "CASCADE", + }, + ) message: import("./Message").Message; @BeforeRemove()