This commit is contained in:
Erik 2022-09-11 10:37:14 +03:00
parent 812d9d27ba
commit 2daf1cfbd7
Signed by untrusted user: Navy.gif
GPG Key ID: 811EC0CD80E7E5FB
3 changed files with 3 additions and 2 deletions

View File

@ -90,7 +90,7 @@ class CaseCommand extends SlashCommand {
if (guild._settings.modpoints.enabled) description += '\n' + invoker.format('COMMAND_CASE_MODPOINTS', {
points: infraction.points,
expires: infraction.expiration
expires: `<t:${Math.round(infraction.expiration / 1000)}:R>`
});
description += '\n\n' + invoker.format('COMMAND_CASE_REASON', { reason: infraction.reason });

View File

@ -38,8 +38,8 @@ class SelfroleCommand extends SlashCommand {
const ownHighest = me.roles.highest;
const memberRoles = member.roles.cache.map((r) => r.id);
const tooHigh = roles?.value.filter((r) => r.position > ownHighest.position);
const invalid = roles?.value.filter((r) => !selfrole.roles.includes(r.id)) || [];
const tooHigh = roles?.value.filter((r) => r.position > ownHighest.position && !invalid.includes(r.id)) || [];
const _roles = roles?.value.filter((r) => selfrole.roles.includes(r.id) && !tooHigh.some((x) => x.id === r.id)) || [];
// console.log(tooHigh, invalid, _roles);
let warning = '';

View File

@ -128,6 +128,7 @@ class ModerationPoints extends Setting {
).join('\n'),
inline: true
},
{ name: ZeroWidthChar, value: ZeroWidthChar, inline: true },
{
name: 'SETTING_MODPOINTS_ASSOCIATIONS',
value: Object.entries(setting.associations).map(([type, pts]) => `**${type}**: \`${pts}\``).join('\n') || '**N/A**'