From 639fc9c7a5f9103c91f6fa4be189f44c089f267e Mon Sep 17 00:00:00 2001 From: Nuckyz <61953774+Nuckyz@users.noreply.github.com> Date: Fri, 9 Feb 2024 17:59:40 -0300 Subject: [PATCH] DisableDMCallIdle -> DisableCallIdle; add more functionality --- .../{disableDMCallIdle => disableCallIdle}/index.ts | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) rename src/plugins/{disableDMCallIdle => disableCallIdle}/index.ts (74%) diff --git a/src/plugins/disableDMCallIdle/index.ts b/src/plugins/disableCallIdle/index.ts similarity index 74% rename from src/plugins/disableDMCallIdle/index.ts rename to src/plugins/disableCallIdle/index.ts index 5738dc238..904d53b03 100644 --- a/src/plugins/disableDMCallIdle/index.ts +++ b/src/plugins/disableCallIdle/index.ts @@ -16,12 +16,14 @@ * along with this program. If not, see . */ +import { migratePluginSettings } from "@api/Settings"; import { Devs } from "@utils/constants"; import definePlugin from "@utils/types"; +migratePluginSettings("DisableCallIdle", "DisableDMCallIdle"); export default definePlugin({ - name: "DisableDMCallIdle", - description: "Disables automatically getting kicked from a DM voice call after 3 minutes.", + name: "DisableCallIdle", + description: "Disables automatically getting kicked from a DM voice call after 3 minutes and being moved to an AFK voice channel.", authors: [Devs.Nuckyz], patches: [ { @@ -30,6 +32,13 @@ export default definePlugin({ match: /,?(?=this\.idleTimeout=new \i\.Timeout)/, replace: ";return;" } + }, + { + find: "handleIdleUpdate(){", + replacement: { + match: /(?<=_initialize\(\){)/, + replace: "return;" + } } ] });