WIP: Refactor Aurora (3.0.0) #29
1 changed files with 23 additions and 20 deletions
|
@ -96,26 +96,29 @@ class ImportAuroraView(ui.View):
|
||||||
else:
|
else:
|
||||||
duration = None
|
duration = None
|
||||||
|
|
||||||
Moderation.log(
|
try:
|
||||||
bot=interaction.client,
|
Moderation.log(
|
||||||
guild_id=self.ctx.guild.id,
|
bot=interaction.client,
|
||||||
moderator_id=case["moderator_id"],
|
guild_id=self.ctx.guild.id,
|
||||||
moderation_type=case["moderation_type"],
|
moderator_id=case["moderator_id"],
|
||||||
target_type=case["target_type"],
|
moderation_type=case["moderation_type"],
|
||||||
target_id=case["target_id"],
|
target_type=case["target_type"],
|
||||||
role_id=case["role_id"],
|
target_id=case["target_id"],
|
||||||
duration=duration,
|
role_id=case["role_id"],
|
||||||
reason=case["reason"],
|
duration=duration,
|
||||||
timestamp=case["timestamp"],
|
reason=case["reason"],
|
||||||
resolved=case["resolved"],
|
timestamp=case["timestamp"],
|
||||||
resolved_by=case["resolved_by"],
|
resolved=case["resolved"],
|
||||||
resolved_reason=case["resolve_reason"],
|
resolved_by=case["resolved_by"],
|
||||||
expired=case["expired"],
|
resolved_reason=case["resolve_reason"],
|
||||||
changes=changes,
|
expired=case["expired"],
|
||||||
metadata=metadata,
|
changes=changes,
|
||||||
database=database,
|
metadata=metadata,
|
||||||
return_obj=False
|
database=database,
|
||||||
)
|
return_obj=False
|
||||||
|
)
|
||||||
|
except Exception as e:
|
||||||
|
failed_cases.append(str(case["moderation_id"]) + f": {e}")
|
||||||
|
|
||||||
await interaction.edit_original_response(content="Import complete.")
|
await interaction.edit_original_response(content="Import complete.")
|
||||||
if failed_cases:
|
if failed_cases:
|
||||||
|
|
Loading…
Reference in a new issue