From ac0e720de19e452b75cd1a13cb576b0dec242721 Mon Sep 17 00:00:00 2001 From: Julius Marminge Date: Sat, 28 Feb 2026 23:16:03 -0800 Subject: [PATCH] fine there --- apps/server/src/attachmentPaths.ts | 2 +- apps/server/src/imageMime.ts | 2 -- .../server/src/orchestration/Layers/ProjectionPipeline.ts | 8 ++------ apps/server/src/wsServer.ts | 7 +++++-- 4 files changed, 8 insertions(+), 11 deletions(-) diff --git a/apps/server/src/attachmentPaths.ts b/apps/server/src/attachmentPaths.ts index f9fb6056691061b3580ff10b55ecdeb8c38bb596..7023d5a3aee0648f5c52d527e6d0426b24e0545a 100644 --- a/apps/server/src/attachmentPaths.ts +++ b/apps/server/src/attachmentPaths.ts @@ -1,6 +1,6 @@ import path from "node:path"; -import { ATTACHMENTS_ROUTE_PREFIX } from "./imageMime.ts"; +export const ATTACHMENTS_ROUTE_PREFIX = "/attachments"; export function normalizeAttachmentRelativePath(rawRelativePath: string): string | null { const normalized = path.normalize(rawRelativePath).replace(/^[/\\]+/, ""); diff --git a/apps/server/src/imageMime.ts b/apps/server/src/imageMime.ts index f808cefdcd24ba980cb2749a178783b57c05941d..249deff0ca8efb37a8708c6fbe3039a9aa3a2ca4 100644 --- a/apps/server/src/imageMime.ts +++ b/apps/server/src/imageMime.ts @@ -1,7 +1,5 @@ import Mime from "@effect/platform-node/Mime"; -export const ATTACHMENTS_ROUTE_PREFIX = "/attachments"; - export const IMAGE_EXTENSION_BY_MIME_TYPE: Record = { "image/avif": ".avif", "image/bmp": ".bmp", diff --git a/apps/server/src/orchestration/Layers/ProjectionPipeline.ts b/apps/server/src/orchestration/Layers/ProjectionPipeline.ts index 45e6196b5027237164462a4507cb73047dee0647..8f8e01a512f865d29749f02a4b97261893fd9539 100644 --- a/apps/server/src/orchestration/Layers/ProjectionPipeline.ts +++ b/apps/server/src/orchestration/Layers/ProjectionPipeline.ts @@ -37,12 +37,8 @@ import { OrchestrationProjectionPipeline, type OrchestrationProjectionPipelineShape, } from "../Services/ProjectionPipeline.ts"; -import { attachmentRouteToRelativePath } from "../../attachmentPaths.ts"; -import { - ATTACHMENTS_ROUTE_PREFIX, - inferImageExtension, - parseBase64DataUrl, -} from "../../imageMime.ts"; +import { ATTACHMENTS_ROUTE_PREFIX, attachmentRouteToRelativePath } from "../../attachmentPaths.ts"; +import { inferImageExtension, parseBase64DataUrl } from "../../imageMime.ts"; export const ORCHESTRATION_PROJECTOR_NAMES = { projects: "projection.projects", diff --git a/apps/server/src/wsServer.ts b/apps/server/src/wsServer.ts index 85991dc2bbf8d22c80be7e4cb93df4201d0bb32d..c40ef39a4c99c9b4c8dae58cac1844ac560fed92 100644 --- a/apps/server/src/wsServer.ts +++ b/apps/server/src/wsServer.ts @@ -55,8 +55,11 @@ import { Open } from "./open"; import { ServerConfig } from "./config"; import { GitCore } from "./git/Services/GitCore.ts"; import { tryHandleProjectFaviconRequest } from "./projectFaviconRoute"; -import { normalizeAttachmentRelativePath, resolveAttachmentRelativePath } from "./attachmentPaths"; -import { ATTACHMENTS_ROUTE_PREFIX } from "./imageMime.ts"; +import { + ATTACHMENTS_ROUTE_PREFIX, + normalizeAttachmentRelativePath, + resolveAttachmentRelativePath, +} from "./attachmentPaths"; /** * ServerShape - Service API for server lifecycle control. -- 2.54.0