From 3ec3192f3f0117d661c58d8a4321b3aabac6579d Mon Sep 17 00:00:00 2001 From: Caden Buckhalt Date: Fri, 3 May 2024 10:24:32 -0700 Subject: [PATCH] fix FormattedSession type to be what FileExportManager expects --- .../formatters/formatExportableSessions.ts | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/lib/network-exporters/formatters/formatExportableSessions.ts b/lib/network-exporters/formatters/formatExportableSessions.ts index 1c88be3e..a53ce748 100644 --- a/lib/network-exporters/formatters/formatExportableSessions.ts +++ b/lib/network-exporters/formatters/formatExportableSessions.ts @@ -8,13 +8,18 @@ import { sessionFinishTimeProperty, sessionProperty, sessionStartTimeProperty, + type NcNode, + type NcEntity, + type NcEdge, } from '@codaco/shared-consts'; import { hash } from 'ohash'; import { env } from '~/env.mjs'; import type { RouterOutputs } from '~/trpc/shared'; type FormattedSession = { - sessionNetwork: NcNetwork; + ego: NcEntity | undefined; + nodes: NcNode[]; + edges: NcEdge[]; sessionVariables: { [caseProperty]: string; [sessionProperty]: string; @@ -65,6 +70,6 @@ export const formatExportableSessions = ( return { ...sessionNetwork, sessionVariables, - }; + } as FormattedSession; }); };