From 8a0b5e6b1dc45856b6017efbdb202ff90d723662 Mon Sep 17 00:00:00 2001 From: Rahul Imran Date: Sat, 2 Mar 2024 23:52:45 +0000 Subject: [PATCH] Add detection for 9minecraft Add detection for 9minecraft to logs.ts. This should probably go somewhere else but I am just detecting it in the same code as for pastebin.com. Signed-off-by: Rahul Imran --- src/logs.ts | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/logs.ts b/src/logs.ts index 08c5c39b..1998f32d 100644 --- a/src/logs.ts +++ b/src/logs.ts @@ -211,6 +211,15 @@ export async function parseLog(s: string): Promise { .setColor(COLORS.red); return embed; } + if (/(https?:\/\/)?9minecraft\.com\/?.*/g.test(s)) { + const embed = new EmbedBuilder() + .setTitle('9minecraft.com detected') + .setDescription( + 'Please use https://modrinth.com or https://curseforge.com to share and download mods' + ) + .setColor(COLORS.red); + return embed; + } let log = ''; for (const i in providers) {