fix: add Content-Type header to createProjectShare API call

This commit is contained in:
2026-06-28 14:37:49 +02:00
parent e9b6f188c8
commit e2bba8b882
+1 -1
View File
@@ -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<ProjectShare> {
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');