diff --git a/moderation/importers/moderation.py b/moderation/importers/moderation.py index bbe4ec6..65af40e 100644 --- a/moderation/importers/moderation.py +++ b/moderation/importers/moderation.py @@ -60,10 +60,11 @@ class ImportModerationView(ui.View): if "changes" not in case or not case["changes"]: case["changes"] = [] - if "metadata" not in case or not case["metadata"]: - case["metadata"] = {} + if "metadata" not in case: + metadata = {} else: - case["metadata"].update({ + metadata: dict = case["metadata"] + metadata.update({ 'imported_from': 'SeaCogs/Moderation' }) @@ -88,7 +89,7 @@ class ImportModerationView(ui.View): resolved_reason=case["resolve_reason"], expired=case["expired"], changes=case["changes"], - metadata=case["metadata"], + metadata=metadata, database=database, )