3
0
Fork 0
mirror of https://github.com/ZeppelinBot/Zeppelin.git synced 2025-05-10 12:25:02 +00:00

some more patches thanks to ruby

Signed-off-by: GitHub <noreply@github.com>
This commit is contained in:
Tiago R 2023-11-26 14:53:54 +00:00
parent ba4a2b45b8
commit 10bb0b67bc
18 changed files with 69 additions and 52 deletions

View file

@ -1,5 +1,6 @@
import { User, escapeBold, type Snowflake } from "discord.js";
import * as t from "io-ts";
import { renderUsername } from "../../../utils.js";
import { automodTrigger } from "../helpers";
interface ThreadCreateResult {
@ -40,7 +41,7 @@ export const ThreadCreateTrigger = automodTrigger<ThreadCreateResult>()({
const parentName = matchResult.extra.matchedThreadParentName;
const base = `Thread **#${threadName}** (\`${threadId}\`) has been created in the **#${parentName}** (\`${parentId}\`) channel`;
if (threadOwner) {
return `${base} by **${escapeBold(threadOwner.tag)}** (\`${threadOwner.id}\`)`;
return `${base} by **${escapeBold(renderUsername(threadOwner.tag))}** (\`${threadOwner.id}\`)`;
}
return base;
},