( format: FalAIDurationFormat | undefined, duration: number | undefined )
| 1072 | } |
| 1073 | |
| 1074 | function formatFalAIDuration( |
| 1075 | format: FalAIDurationFormat | undefined, |
| 1076 | duration: number | undefined |
| 1077 | ): string | number | undefined { |
| 1078 | if (!format || duration === undefined) return undefined |
| 1079 | |
| 1080 | if (format === 'number') return duration |
| 1081 | if (format === 'seconds') return `${duration}s` |
| 1082 | return String(duration) |
| 1083 | } |
| 1084 | |
| 1085 | function getStringProperty( |
| 1086 | record: Record<string, unknown> | undefined, |