From 9681c62ae8370f7a4d4994d58cf5f67955c86a3e Mon Sep 17 00:00:00 2001 From: Michael SCHAL Date: Wed, 25 Mar 2026 11:12:59 +0100 Subject: [PATCH] fix: resolve logo URL to absolute before passing to Remotion renderer Logo stored as relative /uploads/logos/... was resolving to Remotion's bundle server (port 3000) instead of the app (port 5555). Co-Authored-By: Claude Sonnet 4.6 --- server/routes/remotion.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/server/routes/remotion.ts b/server/routes/remotion.ts index d0aa6e2..59482c8 100644 --- a/server/routes/remotion.ts +++ b/server/routes/remotion.ts @@ -131,7 +131,8 @@ remotionRouter.post("/render", upload.fields([{ name: "images", maxCount: 4 }, { try { const cloudinaryConfig = await dbStorage.getCloudinaryConfig(); if (cloudinaryConfig?.cloudName && cloudinaryConfig?.logoPublicId) { - logoUrl = buildMinioUrl(cloudinaryConfig.cloudName, cloudinaryConfig.logoPublicId, cloudinaryConfig.publicUrl); + const relLogo = buildMinioUrl(cloudinaryConfig.cloudName, cloudinaryConfig.logoPublicId, cloudinaryConfig.publicUrl); + logoUrl = relLogo.startsWith('/') ? `${host}${relLogo}` : relLogo; console.log("🏢 Logo URL:", logoUrl); } } catch (e) {