(modeValue: unknown)
| 142 | } |
| 143 | |
| 144 | function normalizeLegacyStarterMode(modeValue: unknown): 'manual' | 'api' | 'chat' | null { |
| 145 | if (modeValue === 'chat') return 'chat' |
| 146 | if (modeValue === 'api' || modeValue === 'run') return 'api' |
| 147 | if (modeValue === undefined || modeValue === 'manual') return 'manual' |
| 148 | return null |
| 149 | } |
| 150 | |
| 151 | function getSerializedLegacyStarterMode(block: SerializedBlock): 'manual' | 'api' | 'chat' | null { |
| 152 | const fromMetadata = readMetadataSubBlockValue(block, 'startWorkflow') |
no outgoing calls
no test coverage detected