Skip to content

Commit

Permalink
mistake
Browse files Browse the repository at this point in the history
  • Loading branch information
italojohnny committed Jan 21, 2025
1 parent a4f5f33 commit 5190182
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/backend/base/langflow/api/v1/endpoints.py
Original file line number Diff line number Diff line change
Expand Up @@ -720,6 +720,7 @@ async def custom_component_update(
user_id=user.id,
)

template_data = code_request.model_dump().get("template", {}).copy()
component_node["tool_mode"] = code_request.tool_mode

if hasattr(cc_instance, "set_attributes"):
Expand Down Expand Up @@ -751,7 +752,6 @@ async def custom_component_update(
# Preserve previous field values by merging filtered template data into
# the component node's template. Only include entries where the value
# is a dictionary containing the key "value".
template_data = code_request.model_dump().get("template", {})
filtered_data = {k: v for k, v in template_data.items() if isinstance(v, dict) and "value" in v}
component_node["template"] |= filtered_data

Expand Down

0 comments on commit 5190182

Please sign in to comment.