+debug
This commit is contained in:
parent
e2486e53a8
commit
f6feb75e29
1 changed files with 10 additions and 0 deletions
|
@ -9,6 +9,12 @@ import { LogsPlugin } from "../../Logs/LogsPlugin";
|
|||
|
||||
export async function clearExpiredMutes(pluginData: GuildPluginData<MutesPluginType>) {
|
||||
const expiredMutes = await pluginData.state.mutes.getExpiredMutes();
|
||||
if (pluginData.guild.id === "140933721929940992") {
|
||||
// tslint:disable-next-line:no-console
|
||||
console.log(
|
||||
`Expired mutes (${expiredMutes.length}) for 140933721929940992: ${expiredMutes.map(m => m.user_id).join(", ")}`,
|
||||
);
|
||||
}
|
||||
for (const mute of expiredMutes) {
|
||||
const member = await resolveMember(pluginData.client, pluginData.guild, mute.user_id);
|
||||
|
||||
|
@ -47,4 +53,8 @@ export async function clearExpiredMutes(pluginData: GuildPluginData<MutesPluginT
|
|||
|
||||
pluginData.state.events.emit("unmute", mute.user_id);
|
||||
}
|
||||
if (pluginData.guild.id === "140933721929940992") {
|
||||
// tslint:disable-next-line:no-console
|
||||
console.log("Finished expired mutes loop for 140933721929940992");
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue