WIP: Moderation type registry #26
2 changed files with 5 additions and 0 deletions
|
@ -1002,6 +1002,7 @@ class Aurora(commands.Cog):
|
|||
None,
|
||||
None,
|
||||
reason,
|
||||
metadata={"interval": interval}
|
||||
)
|
||||
await interaction.edit_original_response(content=f"Slowmode in {channel.mention} has been set to {interval} seconds! (Case `#{moderation.id:,}`)\n**Reason** - `{reason}`")
|
||||
await log(interaction, moderation.id)
|
||||
|
|
|
@ -188,13 +188,17 @@ async def case_factory(interaction: Interaction, moderation: Moderation) -> Embe
|
|||
|
||||
if moderation.metadata:
|
||||
if moderation.metadata["imported_from"]:
|
||||
del moderation.metadata["imported_from"]
|
||||
embed.description += (
|
||||
f"\n**Imported From:** {moderation.metadata['imported_from']}"
|
||||
)
|
||||
if moderation.metadata["imported_timestamp"]:
|
||||
del moderation.metadata["imported_timestamp"]
|
||||
embed.description += (
|
||||
f"\n**Imported Timestamp:** <t:{moderation.metadata['imported_timestamp']}> | <t:{moderation.metadata['imported_timestamp']}:R>"
|
||||
)
|
||||
for key, value in moderation.metadata.items():
|
||||
embed.description += f"\n**{key.title()}:** {value}"
|
||||
|
||||
embed.add_field(name="Reason", value=box(moderation.reason), inline=False)
|
||||
|
||||
|
|
Loading…
Reference in a new issue