(value: string | undefined, prefix: string)
| 203 | |
| 204 | /** Strips a protobuf enum prefix (e.g. `WORKFLOW_EXECUTION_STATUS_RUNNING` → `RUNNING`). */ |
| 205 | export function stripEnumPrefix(value: string | undefined, prefix: string): string | null { |
| 206 | if (!value) return null |
| 207 | return value.startsWith(prefix) ? value.slice(prefix.length) : value |
| 208 | } |
| 209 | |
| 210 | /** |
| 211 | * Formats a seconds count as a protobuf JSON duration string (e.g. 3600 → `"3600s"`). |
no outgoing calls
no test coverage detected