diff --git a/apps/server/src/orchestration/Errors.ts b/apps/server/src/orchestration/Errors.ts index 5882ead3e8e069b9bf953881f4026cedf9834677..1ea038e1d1357f0f49cc82b8862f36aecb316fb0 100644 --- a/apps/server/src/orchestration/Errors.ts +++ b/apps/server/src/orchestration/Errors.ts @@ -1,8 +1,6 @@ import { SchemaIssue, Schema } from "effect"; -import type { - ProjectionRepositoryError, -} from "../persistence/Errors.ts"; +import type { ProjectionRepositoryError } from "../persistence/Errors.ts"; export class OrchestrationCommandJsonParseError extends Schema.TaggedErrorClass()( "OrchestrationCommandJsonParseError", @@ -110,7 +108,7 @@ export function toProjectorDecodeError(eventType: string) { export function toOrchestrationJsonParseError(cause: unknown) { return new OrchestrationCommandJsonParseError({ - detail: `Failed to parse orchestration command JSON: ${cause}`, + detail: `Failed to parse orchestration command JSON`, cause, }); } @@ -119,7 +117,7 @@ export function toListenerCallbackError(listener: "read-model" | "domain-event") return (cause: unknown): OrchestrationListenerCallbackError => new OrchestrationListenerCallbackError({ listener, - detail: `Failed to invoke orchestration ${listener} listener: ${cause}`, + detail: `Failed to invoke orchestration ${listener} listener`, cause, }); }