mirror of https://github.com/FlowiseAI/Flowise.git
Bugfix/In-mem VS not able to load document (#2542)
fix where in-mem VS not able to load documentpull/2543/head flowise-components@1.8.1
parent
04e0ce1783
commit
6a58ae4e80
|
|
@ -379,6 +379,7 @@ export const saveUpsertFlowData = (nodeData: INodeData, upsertHistory: Record<st
|
|||
/**
|
||||
* Check if doc loader should be bypassed, ONLY if doc loader is connected to a vector store
|
||||
* Reason being we dont want to load the doc loader again whenever we are building the flow, because it was already done during upserting
|
||||
* EXCEPT if the vector store is a memory vector store
|
||||
* TODO: Remove this logic when we remove doc loader nodes from the canvas
|
||||
* @param {IReactFlowNode} reactFlowNode
|
||||
* @param {IReactFlowNode[]} reactFlowNodes
|
||||
|
|
@ -406,7 +407,8 @@ const checkIfDocLoaderShouldBeIgnored = (
|
|||
|
||||
if (targetNodeId) {
|
||||
const targetNodeCategory = reactFlowNodes.find((nd) => nd.id === targetNodeId)?.data.category || ''
|
||||
if (targetNodeCategory === 'Vector Stores') {
|
||||
const targetNodeName = reactFlowNodes.find((nd) => nd.id === targetNodeId)?.data.name || ''
|
||||
if (targetNodeCategory === 'Vector Stores' && targetNodeName !== 'memoryVectorStore') {
|
||||
return true
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue