(error: unknown)
| 13 | * Returns whether a filesystem error means the requested path is absent. |
| 14 | */ |
| 15 | export function isMissingPathError(error: unknown): boolean { |
| 16 | return ( |
| 17 | typeof error === 'object' && |
| 18 | error !== null && |
| 19 | 'code' in error && |
| 20 | (error.code === 'ENOENT' || error.code === 'ENOTDIR') |
| 21 | ); |
| 22 | } |
no outgoing calls
no test coverage detected