MCPcopy
hub / github.com/FlowiseAI/Flowise / stripProtectedFields

Function stripProtectedFields

packages/server/src/utils/stripProtectedFields.ts:26–32  ·  view source on GitHub ↗
(body: T)

Source from the content-addressed store, hash-verified

24 * Object.assign(entity, stripProtectedFields(req.body))
25 */
26export function stripProtectedFields<T extends Record<string, unknown>>(body: T): Omit<T, ProtectedField> {
27 const sanitized = { ...body }
28 for (const field of PROTECTED_FIELDS) {
29 delete sanitized[field]
30 }
31 return sanitized as Omit<T, ProtectedField>
32}

Callers 13

toEntityMethod · 0.90
saveChatflowFunction · 0.90
updateChatflowFunction · 0.90
createDatasetFunction · 0.90
updateDatasetFunction · 0.90
addDatasetRowFunction · 0.90
updateDatasetRowFunction · 0.90
saveCustomTemplateFunction · 0.90
createEvaluationFunction · 0.90
saveCustomTemplateFunction · 0.90
createAssistantFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected