From 0f53b0ba061ebc7a56f77f93c5a0f8cd92e5edfd Mon Sep 17 00:00:00 2001 From: mstfyldz Date: Sat, 30 May 2026 18:47:08 +0300 Subject: [PATCH] fix: coolify deployment build errors (missing public dir and dynamic server errors) --- app/actions.ts | 5 ++++- public/.gitkeep | 0 2 files changed, 4 insertions(+), 1 deletion(-) create mode 100644 public/.gitkeep diff --git a/app/actions.ts b/app/actions.ts index 74ec4a1..3485990 100644 --- a/app/actions.ts +++ b/app/actions.ts @@ -296,7 +296,10 @@ export async function getAdminSession() { const token = cookieStore.get(COOKIE_NAME)?.value; if (!token) return null; return verifyToken(token); - } catch (error) { + } catch (error: any) { + if (error?.digest === 'DYNAMIC_SERVER_USAGE' || error?.message?.includes('Dynamic server usage')) { + throw error; + } console.error("Error reading admin session:", error); return null; } diff --git a/public/.gitkeep b/public/.gitkeep new file mode 100644 index 0000000..e69de29