From 8a2152395fa0a4315d475c446bd3c1551ca3a1a9 Mon Sep 17 00:00:00 2001 From: Peter KW Date: Mon, 18 Mar 2024 01:31:58 +0100 Subject: [PATCH] Small fixes --- frontend/src/Components/AddProject.tsx | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/frontend/src/Components/AddProject.tsx b/frontend/src/Components/AddProject.tsx index 9fdf8e9..45814e3 100644 --- a/frontend/src/Components/AddProject.tsx +++ b/frontend/src/Components/AddProject.tsx @@ -13,7 +13,7 @@ import Button from "./Button"; function CreateProject(props: { name: string; description: string }): boolean { const project: NewProject = { name: props.name, - description: props.name, + description: props.description, }; let created = false; @@ -21,13 +21,10 @@ function CreateProject(props: { name: string; description: string }): boolean { api .createProject(project, localStorage.getItem("accessToken") ?? "") .then((response: APIResponse) => { - //vv_FOR DEBGUGGING_vv - console.log(localStorage.getItem("accessToken")); - if (response.success) { created = true; } else { - console.error("Could not add project"); + console.error(response.message); } }) .catch((error) => {