# core/converters/failure.converter.ts

> 3 lines of code and 1 definition.

Tree: Bane's Lab Deploy
Language: typescript
Layer: processing
Canonical: https://banes-lab.com/anatomy/deploy#file-deploy-core-converters-failure-converter-ts
Source text: https://banes-lab.com/source/deploy/core/converters/failure.converter.ts.txt

Listed in [core/converters](https://banes-lab.com/api/source/deploy/core/converters.md), after [core/converters/catalog.converter.ts](https://banes-lab.com/source/deploy/core/converters/catalog.converter.ts.md) and before [core/converters/index.converter.ts](https://banes-lab.com/source/deploy/core/converters/index.converter.ts.md).

## Definitions

- `messageOf` (lexical_declaration, line 1, exported)

## Contained in

- [core/converters](https://banes-lab.com/anatomy/deploy/folder-deploy-core-converters.md)

## Used by

- [core/probes/vcs.probe.ts](https://banes-lab.com/source/deploy/core/probes/vcs.probe.ts.md)
- [core/reporters/notification.reporter.ts](https://banes-lab.com/source/deploy/core/reporters/notification.reporter.ts.md)
- [core/steps/setup.step.ts](https://banes-lab.com/source/deploy/core/steps/setup.step.ts.md)
- [runtime/entrypoints/deployment.entrypoint.ts](https://banes-lab.com/source/deploy/runtime/entrypoints/deployment.entrypoint.ts.md)
- [runtime/entrypoints/nginx.entrypoint.ts](https://banes-lab.com/source/deploy/runtime/entrypoints/nginx.entrypoint.ts.md)

## Linked from

- [core/probes](https://banes-lab.com/anatomy/deploy/folder-deploy-core-probes.md)
- [core/reporters](https://banes-lab.com/anatomy/deploy/folder-deploy-core-reporters.md)
- [core/steps](https://banes-lab.com/anatomy/deploy/folder-deploy-core-steps.md)
- [runtime/entrypoints](https://banes-lab.com/anatomy/deploy/folder-deploy-runtime-entrypoints.md)

## Source

```typescript
export const messageOf = function messageOf(error: unknown): string {
    return error instanceof Error ? error.message : String(error);
};
```
