fix(moderation): swapped a subtraction action
Some checks failed
Pylint / Pylint (push) Failing after 1m14s
Some checks failed
Pylint / Pylint (push) Failing after 1m14s
This commit is contained in:
parent
bfaad63920
commit
854a1f14e5
1 changed files with 1 additions and 1 deletions
|
@ -76,7 +76,7 @@ class Moderation(commands.Cog):
|
||||||
elif entry.action == discord.AuditLogAction.member_update:
|
elif entry.action == discord.AuditLogAction.member_update:
|
||||||
if entry.after.timed_out_until is not None:
|
if entry.after.timed_out_until is not None:
|
||||||
timed_out_until_aware = entry.after.timed_out_until.replace(tzinfo=timezone.utc)
|
timed_out_until_aware = entry.after.timed_out_until.replace(tzinfo=timezone.utc)
|
||||||
duration_datetime = datetime.now(tz=timezone.utc) + timed_out_until_aware
|
duration_datetime = timed_out_until_aware - datetime.now(tz=timezone.utc)
|
||||||
minutes = round(duration_datetime.total_seconds() / 60)
|
minutes = round(duration_datetime.total_seconds() / 60)
|
||||||
duration = timedelta(minutes=minutes)
|
duration = timedelta(minutes=minutes)
|
||||||
moderation_type = 'TIMEOUT'
|
moderation_type = 'TIMEOUT'
|
||||||
|
|
Loading…
Reference in a new issue