mirror of
https://github.com/farcasclaudiu/Flowise.git
synced 2026-06-28 15:00:57 +03:00
Chore/remove app server functions from utils file (#3671)
* remove app server functions from utils file * hide override config variables if its empty
This commit is contained in:
@@ -25,6 +25,7 @@ import { StatusCodes } from 'http-status-codes'
|
||||
import { getErrorMessage } from '../errors/utils'
|
||||
import { v4 as uuidv4 } from 'uuid'
|
||||
import { FLOWISE_COUNTER_STATUS, FLOWISE_METRIC_COUNTERS } from '../Interface.Metrics'
|
||||
import { Variable } from '../database/entities/Variable'
|
||||
/**
|
||||
* Upsert documents
|
||||
* @param {Request} req
|
||||
@@ -157,6 +158,7 @@ export const upsertVector = async (req: Request, isInternal: boolean = false) =>
|
||||
const { startingNodeIds, depthQueue } = getStartingNodes(filteredGraph, stopNodeId)
|
||||
|
||||
/*** Get API Config ***/
|
||||
const availableVariables = await appServer.AppDataSource.getRepository(Variable).find()
|
||||
const { nodeOverrides, variableOverrides, apiOverrideStatus } = getAPIOverrideConfig(chatflow)
|
||||
|
||||
// For "files" input, add a new node override with the actual input name such as pdfFile, txtFile, etc.
|
||||
@@ -189,6 +191,7 @@ export const upsertVector = async (req: Request, isInternal: boolean = false) =>
|
||||
overrideConfig: incomingInput?.overrideConfig,
|
||||
apiOverrideStatus,
|
||||
nodeOverrides,
|
||||
availableVariables,
|
||||
variableOverrides,
|
||||
cachePool: appServer.cachePool,
|
||||
isUpsert,
|
||||
|
||||
Reference in New Issue
Block a user