Skip to content

Commit

Permalink
Update G2Loader.py
Browse files Browse the repository at this point in the history
  • Loading branch information
antaenc authored Mar 8, 2024
1 parent a934d92 commit 01171ed
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions G2Loader.py
Original file line number Diff line number Diff line change
Expand Up @@ -976,15 +976,14 @@ def g2thread_error(msg, action):

if dsrc_action == 'X':
dsrc_action_str = 'reevaluateRecord()'

# Check if the redo record is a REPAIR_ENTITY one, call reevaluateEntity() if so
# {'UMF_PROC': {'NAME': 'REPAIR_ENTITY', 'PARAMS': [{'PARAM': {'NAME': 'ENTITY_ID', 'VALUE': '32705738'}}]}}
if not data_source and not record_id:
entity_id = row.get("UMF_PROC", {}).get("PARAMS", {})[0].get("PARAM", {}).get("VALUE", None)
if entity_id:
g2_engine_.reevaluateEntity(entity_id)
else:
g2thread_error(f"Unable to process redo record format!", dsrc_action_str)
g2thread_error("Unable to process redo record format!", dsrc_action_str)
else:
g2_engine_.reevaluateRecord(data_source, record_id, 0)

Expand Down

0 comments on commit 01171ed

Please sign in to comment.