(error: unknown)
| 114 | } |
| 115 | |
| 116 | function getErrorCode(error: unknown): string | undefined { |
| 117 | if (typeof error !== "object" || error === null || !("code" in error)) { |
| 118 | return undefined; |
| 119 | } |
| 120 | |
| 121 | return typeof error.code === "string" ? error.code : undefined; |
| 122 | } |
| 123 | |
| 124 | function formatCgroupReadError(error: unknown): string { |
| 125 | const message = error instanceof Error ? error.message : String(error); |
no outgoing calls
no test coverage detected