mirror of
https://github.com/ZeppelinBot/Zeppelin.git
synced 2025-05-10 12:25:02 +00:00
Update to Knub30.0.0-beta.37 and Eris 0.15, first pass
This commit is contained in:
parent
84da543205
commit
f6be4f4af6
133 changed files with 6507 additions and 380 deletions
|
@ -13,9 +13,9 @@ import { Case } from "../../../data/entities/Case";
|
|||
* Create an UNBAN case automatically when a user is unbanned manually.
|
||||
* Attempts to find the unban's details in the audit log.
|
||||
*/
|
||||
export const CreateUnbanCaseOnManualUnbanEvt = modActionsEvt(
|
||||
"guildBanRemove",
|
||||
async ({ pluginData, args: { guild, user } }) => {
|
||||
export const CreateUnbanCaseOnManualUnbanEvt = modActionsEvt({
|
||||
event: "guildBanRemove",
|
||||
async listener({ pluginData, args: { guild, user } }) {
|
||||
if (isEventIgnored(pluginData, IgnoredEventType.Unban, user.id)) {
|
||||
clearIgnoredEvents(pluginData, IgnoredEventType.Unban, user.id);
|
||||
return;
|
||||
|
@ -38,7 +38,7 @@ export const CreateUnbanCaseOnManualUnbanEvt = modActionsEvt(
|
|||
|
||||
mod = await resolveUser(pluginData.client, modId);
|
||||
|
||||
const config = mod instanceof UnknownUser ? pluginData.config.get() : pluginData.config.getForUser(mod);
|
||||
const config = mod instanceof UnknownUser ? pluginData.config.get() : await pluginData.config.getForUser(mod);
|
||||
|
||||
if (config.create_cases_for_manual_actions) {
|
||||
createdCase = await casesPlugin.createCase({
|
||||
|
@ -69,4 +69,4 @@ export const CreateUnbanCaseOnManualUnbanEvt = modActionsEvt(
|
|||
|
||||
pluginData.state.events.emit("unban", user.id);
|
||||
},
|
||||
);
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue