From 0730087111d1150e5e86d2eb328cbfd03e7c8531 Mon Sep 17 00:00:00 2001 From: Rhea Parekh Date: Mon, 18 Jun 2018 22:28:44 +0530 Subject: [PATCH] import: Add elif condition for 'processing_emojis' in 'import_uploads_s3'. 'processing_emojis' should have an 'elif' condition here as we want the function to work for avatars, emojis or uploads one at a time. --- zerver/lib/import_realm.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/zerver/lib/import_realm.py b/zerver/lib/import_realm.py index 99890d37e438c..d4c40fd33110a 100644 --- a/zerver/lib/import_realm.py +++ b/zerver/lib/import_realm.py @@ -330,7 +330,7 @@ def import_uploads_s3(bucket_name: str, import_dir: Path, processing_avatars: bo key.key = avatar_path if record['s3_path'].endswith('.original'): key.key += '.original' - if processing_emojis: + elif processing_emojis: # For emojis we follow the function 'upload_emoji_image' emoji_path = RealmEmoji.PATH_ID_TEMPLATE.format( realm_id=record['realm_id'],