diff --git a/zerver/tests/test_events.py b/zerver/tests/test_events.py index 855a1a0638..017cc9eaa1 100644 --- a/zerver/tests/test_events.py +++ b/zerver/tests/test_events.py @@ -2767,7 +2767,6 @@ class EventsRegisterTest(ZulipTestCase): ('acting_user_id', check_int), ('export_data', check_dict_only([ ('export_path', check_string), - ('deleted_timestamp', equals(None)) ])), ]))), ]) diff --git a/zerver/worker/queue_processors.py b/zerver/worker/queue_processors.py index 22c1afd002..8bb47368ee 100644 --- a/zerver/worker/queue_processors.py +++ b/zerver/worker/queue_processors.py @@ -619,10 +619,11 @@ class DeferredWorker(QueueProcessingWorker): delete_after_upload=True) assert public_url is not None - # Store the relative URL of the export. + # Update the extra_data field now that the export is complete. export_event = RealmAuditLog.objects.get(id=event['id']) - export_event.extra_data = ujson.dumps({'export_path': urllib.parse.urlparse(public_url).path, - 'deleted_timestamp': None}) + export_event.extra_data = ujson.dumps(dict( + export_path=urllib.parse.urlparse(public_url).path, + )) export_event.save(update_fields=['extra_data']) # Send a private message notification letting the user who