Skip to content

Commit

Permalink
fix: flow export endpoint exporting folder (#3227)
Browse files Browse the repository at this point in the history
Fixed flows export function exporting folder instead of flow when flow count is 1
  • Loading branch information
lucaseduoli authored Aug 7, 2024
1 parent 22305fe commit 10af388
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/backend/base/langflow/api/v1/flows.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
from sqlmodel import Session, and_, col, select

from langflow.api.utils import remove_api_keys, validate_is_component
from langflow.api.v1.schemas import FlowListCreate, FlowListRead
from langflow.api.v1.schemas import FlowListCreate
from langflow.initial_setup.setup import STARTER_FOLDER_NAME
from langflow.services.auth.utils import get_current_active_user
from langflow.services.database.models.flow import Flow, FlowCreate, FlowRead, FlowUpdate
Expand Down Expand Up @@ -395,4 +395,4 @@ async def download_multiple_file(
headers={"Content-Disposition": f"attachment; filename={filename}"},
)
else:
return FlowListRead(flows=flows_without_api_keys)
return flows_without_api_keys[0]

0 comments on commit 10af388

Please sign in to comment.