fix edge not connecting on nudges flow

This commit is contained in:
Lucas Oliveira 2025-09-22 17:59:51 -03:00
parent a3a1a17231
commit c3ba459d12

View file

@ -361,22 +361,17 @@ class FlowsService:
flow_json_str = re.sub(
re.escape(old_llm_id), new_llm_id, flow_json_str
)
if old_llm_text_id:
flow_json_str = re.sub(
re.escape(old_llm_text_id), new_llm_text_id, flow_json_str
)
flow_json_str = re.sub(
re.escape(old_llm_id.split("-")[0]),
new_llm_id.split("-")[0],
flow_json_str,
)
if old_llm_text_id:
flow_json_str = re.sub(
re.escape(old_llm_text_id), new_llm_text_id, flow_json_str
)
flow_json_str = re.sub(
re.escape(old_llm_text_id.split("-")[0]),
new_llm_text_id.split("-")[0],
flow_json_str,
)
# Convert back to JSON
flow_data = json.loads(flow_json_str)