diff --git a/queue_services/entity-filer/src/entity_filer/filing_processors/amalgamation_application.py b/queue_services/entity-filer/src/entity_filer/filing_processors/amalgamation_application.py index d2c42cf75..f345adb72 100644 --- a/queue_services/entity-filer/src/entity_filer/filing_processors/amalgamation_application.py +++ b/queue_services/entity-filer/src/entity_filer/filing_processors/amalgamation_application.py @@ -18,7 +18,7 @@ from typing import Dict import sentry_sdk -from business_model import AmalgamatingBusiness, Amalgamation, Document, Filing, LegalEntity, RegistrationBootstrap, db +from legal_api.models import AmalgamatingBusiness, Amalgamation, Document, Filing, LegalEntity, RegistrationBootstrap, db from entity_filer.exceptions import DefaultException from entity_filer.filing_meta import FilingMeta @@ -85,13 +85,13 @@ def create_amalgamating_businesses(amalgamation_filing: Dict, amalgamation: Amal amalgamating_businesses_json = amalgamation_filing.get("amalgamatingBusinesses", []) for amalgamating_business_json in amalgamating_businesses_json: amalgamating_business = AmalgamatingBusiness() - amalgamating_business.role = amalgamating_business_json.get('role') - identifier = amalgamating_business_json.get('identifier') - if foreign_jurisdiction := amalgamating_business_json.get('foreignJurisdiction'): + amalgamating_business.role = amalgamating_business_json.get("role") + identifier = amalgamating_business_json.get("identifier") + if foreign_jurisdiction := amalgamating_business_json.get("foreignJurisdiction"): amalgamating_business.foreign_identifier = identifier - amalgamating_business.foreign_name = amalgamating_business_json.get('legalName') - amalgamating_business.foreign_jurisdiction = foreign_jurisdiction.get('country').upper() - if region := foreign_jurisdiction.get('region'): + amalgamating_business.foreign_name = amalgamating_business_json.get("legalName") + amalgamating_business.foreign_jurisdiction = foreign_jurisdiction.get("country").upper() + if region := foreign_jurisdiction.get("region"): amalgamating_business.foreign_jurisdiction_region = region.upper() elif business := LegalEntity.find_by_identifier(identifier): amalgamating_business.business_id = business.id