Fixing Noah's project package and removing Words.json from the cache

This commit is contained in:
2025-07-12 21:16:13 -04:00
parent bce2bf234e
commit ba5b14c05a
11 changed files with 27 additions and 3382 deletions

View File

@@ -0,0 +1,16 @@
import { Guild } from "discord.js";
import { SQLCommon } from "../storage/interfaces";
export async function getRegexesForGuild(db: SQLCommon, guild: Guild): Promise<any[]> {
return db.getAllParameterized(
"SELECT * FROM message_regexes WHERE server_snowflake = ?",
[guild.id]
)
}
export async function getRoleExclusionSnowflakesForGuild(db: SQLCommon, guild: Guild): Promise<string[]> {
return (await db.getAllParameterized(
"SELECT role_snowflake FROM message_regex_no_role_check WHERE server_snowflake = ?",
[guild.id]
)).map((o) => (o as any).role_snowflake)
}