fix(moderation): fixed cases sometimes not exporting as files
This commit is contained in:
parent
eed3ad1748
commit
b55e3da63e
1 changed files with 1 additions and 1 deletions
|
@ -1151,7 +1151,7 @@ class Moderation(commands.Cog):
|
|||
case_dict = await self.fetch_case(case, interaction.guild.id)
|
||||
if case_dict:
|
||||
if export:
|
||||
if len(str(case)) > 1800 or export == 'file':
|
||||
if export == 'file' or len(str(case)) > 1800:
|
||||
filename = str(data_manager.cog_data_path(cog_instance=self)) + str(os.sep) + f"moderation_{interaction.guild.id}_case_{case}.json"
|
||||
|
||||
with open(filename, "w", encoding="utf-8") as f:
|
||||
|
|
Loading…
Reference in a new issue