( part: string, )
| 9 | } |
| 10 | |
| 11 | export function parsePipeKeyValue( |
| 12 | part: string, |
| 13 | ): { key: string; value: string } | null { |
| 14 | const colonIndex = part.indexOf(":"); |
| 15 | if (colonIndex === -1) return null; |
| 16 | |
| 17 | const key = part.slice(0, colonIndex).trim().toLowerCase(); |
| 18 | if (!key) return null; |
| 19 | |
| 20 | const value = part.slice(colonIndex + 1).trim(); |
| 21 | return { key, value }; |
| 22 | } |
| 23 | |
| 24 | export function parseBooleanFlag(value?: string): boolean { |
| 25 | if (!value) return true; |
no outgoing calls
no test coverage detected