galactic-bot/structure/client/components/settings/moderation/AutoModeration.js
2020-08-31 10:04:23 -07:00

44 lines
1.1 KiB
JavaScript

const { Setting } = require('../../../../interfaces/');
class AutoModerationSetting extends Setting {
constructor(client) {
super(client, {
name: 'autoModeration',
module: 'moderation',
aliases: ['autoMod'],
resolve: 'GUILD',
default: {
autoModeration: {
enabled: true,
thresholds: {
'35': {
type: 'MUTE',
length: 3600
}
}
}
},
archivable: false
});
}
async handle(message) {
return {
msg: message.format('S_SILENT_SUCCESS', { value: "fuck yourself" }),
error: false
};
}
fields(guild) {
return {
name: "》 Status",
value: guild.format('SETTING_STATUS', { bool: Boolean(guild._settings.autoModeration.enabled) }, true)
};
}
}
module.exports = AutoModerationSetting;