From b47ef34a071030d61e6c446242046b7e49305d6f Mon Sep 17 00:00:00 2001 From: "wont.stream" Date: Mon, 23 Sep 2024 18:41:14 -0400 Subject: [PATCH] fixes --- plugins/eurotilities/modules/noReplyMention.ts | 7 +------ plugins/eurotilities/modules/noTyping.ts | 2 -- plugins/eurotilities/modules/timestampedFiles.ts | 7 +------ 3 files changed, 2 insertions(+), 14 deletions(-) diff --git a/plugins/eurotilities/modules/noReplyMention.ts b/plugins/eurotilities/modules/noReplyMention.ts index 1b91e93..be1ec29 100644 --- a/plugins/eurotilities/modules/noReplyMention.ts +++ b/plugins/eurotilities/modules/noReplyMention.ts @@ -1,19 +1,14 @@ const { flux } = shelter; const { intercept } = flux; -// biome-ignore lint/complexity/noBannedTypes: N/A -let unintercept: Function | null = null; - export default { title: "No Reply Mention", content: "Disable replies by default.", start: () => { - unintercept = intercept((dispatch) => { + intercept((dispatch) => { if (dispatch.type !== "CREATE_PENDING_REPLY") return; dispatch.shouldMention = false; }); - - return true; }, }; diff --git a/plugins/eurotilities/modules/noTyping.ts b/plugins/eurotilities/modules/noTyping.ts index 0d3256c..1555887 100644 --- a/plugins/eurotilities/modules/noTyping.ts +++ b/plugins/eurotilities/modules/noTyping.ts @@ -7,7 +7,5 @@ export default { start: () => { // @ts-ignore intercept("post", /.*typing$/, () => {}); - - return true; }, }; diff --git a/plugins/eurotilities/modules/timestampedFiles.ts b/plugins/eurotilities/modules/timestampedFiles.ts index dc364c6..a17c926 100644 --- a/plugins/eurotilities/modules/timestampedFiles.ts +++ b/plugins/eurotilities/modules/timestampedFiles.ts @@ -1,14 +1,11 @@ const { flux } = shelter; const { intercept } = flux; -// biome-ignore lint/complexity/noBannedTypes: N/A -let unintercept: Function | null = null; - export default { title: "Timestamped Files", content: "Rename uploaded files to the current timestamp.", start: () => { - unintercept = intercept((dispatch) => { + intercept((dispatch) => { if (dispatch?.type === "UPLOAD_ATTACHMENT_ADD_FILES") { for (const { file } of dispatch?.files ?? []) { if (!file?.name) continue; @@ -26,7 +23,5 @@ export default { return dispatch; } }); - - return true; }, };