From e2bba8b882ae4d8cae775ae7ff29827153cf2e5d Mon Sep 17 00:00:00 2001 From: Leopoldadmin Date: Sun, 28 Jun 2026 14:37:49 +0200 Subject: [PATCH] fix: add Content-Type header to createProjectShare API call --- frontend/src/services/api.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend/src/services/api.ts b/frontend/src/services/api.ts index b2f7a16..eb6f825 100644 --- a/frontend/src/services/api.ts +++ b/frontend/src/services/api.ts @@ -450,7 +450,7 @@ export async function getProjectShares(token: string, projectId: string): Promis export async function createProjectShare(token: string, projectId: string, data: { shared_with_email: string; permission?: string }): Promise { const res = await fetch(`${API_BASE}/api/projects/${projectId}/shares`, { method: 'POST', - headers: authHeaders(token), + headers: { ...authHeaders(token), 'Content-Type': 'application/json' }, body: JSON.stringify(data), }); if (!res.ok) throw new Error('Failed to create share');