MCPcopy Index your code
hub / github.com/simstudioai/sim / mergeFilesIntoOutput

Function mergeFilesIntoOutput

apps/sim/executor/utils/start-block.ts:393–404  ·  view source on GitHub ↗
(
  output: NormalizedBlockOutput,
  workflowInput: unknown
)

Source from the content-addressed store, hash-verified

391}
392
393function mergeFilesIntoOutput(
394 output: NormalizedBlockOutput,
395 workflowInput: unknown
396): NormalizedBlockOutput {
397 const files = getFilesFromWorkflowInput(workflowInput)
398 if (files) {
399 output.files = files
400 } else if (isRecordLike(workflowInput) && Object.hasOwn(workflowInput, 'files')) {
401 output.files = undefined
402 }
403 return output
404}
405
406function ensureString(value: unknown): string {
407 return typeof value === 'string' ? value : ''

Callers 6

buildUnifiedStartOutputFunction · 0.85
buildApiOrInputOutputFunction · 0.85
buildChatOutputFunction · 0.85
buildLegacyStarterOutputFunction · 0.85
buildManualTriggerOutputFunction · 0.85

Calls 2

isRecordLikeFunction · 0.90

Tested by

no test coverage detected