From de187227015d8beb3f128086e79a544c7ae54e83 Mon Sep 17 00:00:00 2001 From: eason-pan-bc Date: Fri, 15 Nov 2024 13:52:11 -0800 Subject: [PATCH] change get corp_name logic for continuation in --- .../email_processors/continuation_in_notification.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/queue_services/entity-emailer/src/entity_emailer/email_processors/continuation_in_notification.py b/queue_services/entity-emailer/src/entity_emailer/email_processors/continuation_in_notification.py index f49eecd6c2..8894df87d9 100644 --- a/queue_services/entity-emailer/src/entity_emailer/email_processors/continuation_in_notification.py +++ b/queue_services/entity-emailer/src/entity_emailer/email_processors/continuation_in_notification.py @@ -67,7 +67,9 @@ def _get_pdfs( attach_order += 1 # add receipt - corp_name = filing.filing_json['filing']['continuationIn']['nameRequest'].get('legalName', 'Numbered Company') + if not (corp_name := business.get('legalName')): + legal_type = business.get('legalType') + corp_name = Business.BUSINESSES.get(legal_type, {}).get('numberedDescription') # Debugging logger for #24361, will have another PR before closing the ticket to remove it current_app.logger.debug(