Skip to content

Commit

Permalink
fix: handle missing resume in profile during parsing for update and c…
Browse files Browse the repository at this point in the history
…reate actions in HrFlow
  • Loading branch information
itsnedhir committed Nov 26, 2024
1 parent 595629a commit 9ac253a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/hrflow_connectors/v2/core/hrflow/aisles/profile.py
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ def create(
)
continue

if profile.get("resume", {}).get("raw") is None:
if not profile.get("resume") or profile["resume"].get("raw") is None:
adapter.info(
f"Profile with reference {profile['reference']} has no resume, adding"
" without parsing"
Expand Down Expand Up @@ -269,7 +269,7 @@ def update(
)
profile_to_edit = {**current_profile, **edit}

if profile.get("resume"):
if profile.get("resume") and profile["resume"].get("raw") is not None:
if not current_profile.get("attachments"):
parsing_response = hrflow_client.profile.parsing.add_file(
source_key=parameters.source_key,
Expand Down

0 comments on commit 9ac253a

Please sign in to comment.