add logger

This commit is contained in:
Emily
2024-09-17 13:38:02 +02:00
parent fd5eca29cc
commit 86011c38ce
6 changed files with 50 additions and 17 deletions

View File

@@ -9,6 +9,7 @@ export async function getUserProjectFromId(project_id: string, user: AuthContext
return project;
} else {
if (!user?.logged) return;
if (!project_id) return;
const project = await ProjectModel.findById(project_id);
if (!project) return;
const [hasAccess, role] = await hasAccessToProject(user.id, project_id, project);