diff --git a/packages/backend/src/routes/project/create.ts b/packages/backend/src/routes/project/create.ts index c479bf3..76535ef 100644 --- a/packages/backend/src/routes/project/create.ts +++ b/packages/backend/src/routes/project/create.ts @@ -16,9 +16,9 @@ export default async function projectCreate(req: BunRequest) { ); } - // check if project with blob already exists + // check if project with blob already exists in the organisation const existingProject = await getProjectByBlob(blob); - if (existingProject) { + if (existingProject?.organisationId === parseInt(organisationId, 10)) { return new Response(`project with blob ${blob} already exists`, { status: 400 }); }