From 74800de1fc8dfc5bc5d8dcadbeefce081b082856 Mon Sep 17 00:00:00 2001 From: Priscila Oliveira Date: Thu, 22 May 2025 11:21:06 +0200 Subject: [PATCH] fix(project-creation): Render request errors at the bottom --- static/app/views/projectInstall/createProject.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/static/app/views/projectInstall/createProject.tsx b/static/app/views/projectInstall/createProject.tsx index 724806e4f089ee..ffabea9481d89e 100644 --- a/static/app/views/projectInstall/createProject.tsx +++ b/static/app/views/projectInstall/createProject.tsx @@ -133,7 +133,7 @@ const keyToErrorText: Record = { export function CreateProject() { const api = useApi(); const navigate = useNavigate(); - const [errors, setErrors] = useState(false); + const [errors, setErrors] = useState(); const organization = useOrganization(); const location = useLocation(); const {createNotificationAction, notificationProps} = useCreateNotificationAction(); @@ -339,7 +339,7 @@ export function CreateProject() { ) ); } catch (error) { - setErrors(!!error.responseJSON); + setErrors(error.responseJSON); addErrorMessage(t('Failed to create project %s', `${projectName}`)); // Only log this if the error is something other than: