def METHOD_NAME(self) -> dict:
    """Return the party member as a json object."""
    if self.party_type == Party.PartyTypes.PERSON.value:
        member = {
            'officer': {
                'id': self.id,
                'partyType': self.party_type,
                'firstName': self.first_name,
                'lastName': self.last_name
            }
        }
        if self.title:
            member['title'] = self.title
        if self.middle_initial:
            member['officer']['middleInitial'] = self.middle_initial
    else:
        member = {
            'officer': {
                'id': self.id,
                'partyType': self.party_type,
                'organizationName': self.organization_name,
                'identifier': self.identifier
            }
        }
    member['officer']['email'] = self.email
    if self.delivery_address:
        member_address = self.delivery_address.METHOD_NAME
        if 'addressType' in member_address:
            del member_address['addressType']
        member['deliveryAddress'] = member_address
    if self.mailing_address:
        member_mailing_address = self.mailing_address.METHOD_NAME
        if 'addressType' in member_mailing_address:
            del member_mailing_address['addressType']
        member['mailingAddress'] = member_mailing_address
    else:
        if self.delivery_address:
            member['mailingAddress'] = member['deliveryAddress']
    return member