From 15eb505af4632e7d1417f7991b49037c4ccff182 Mon Sep 17 00:00:00 2001 From: Shreerang Kale Date: Tue, 29 Oct 2024 18:37:08 +0530 Subject: [PATCH] Add default value for env variables array --- .../src/components/projects/create/Configure.tsx | 11 +++++++++++ .../project/overview/Activity/AuctionCard.tsx | 2 +- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/packages/frontend/src/components/projects/create/Configure.tsx b/packages/frontend/src/components/projects/create/Configure.tsx index f4cd0092..c4a2eb45 100644 --- a/packages/frontend/src/components/projects/create/Configure.tsx +++ b/packages/frontend/src/components/projects/create/Configure.tsx @@ -70,6 +70,7 @@ const Configure = () => { maxPrice: DEFAULT_MAX_PRICE, lrn: '', numProviders: 1, + variables: [] }, }); @@ -173,6 +174,7 @@ const Configure = () => { const handleFormSubmit = useCallback( async (createFormData: FieldValues) => { + try { const deployerLrn = createFormData.lrn; const deployer = deployers.find( (deployer) => deployer.deployerLrn === deployerLrn, @@ -268,6 +270,15 @@ const Configure = () => { `/${orgSlug}/projects/create/deploy?projectId=${projectId}`, ); } + } catch (error) { + console.error(error) + toast({ + id: 'error-deploying-app', + title: 'Error deploying app', + variant: 'error', + onDismiss: dismiss, + }); + } }, [client, createProject, dismiss, toast], ); diff --git a/packages/frontend/src/components/projects/project/overview/Activity/AuctionCard.tsx b/packages/frontend/src/components/projects/project/overview/Activity/AuctionCard.tsx index d7ca2be4..6927c2d8 100644 --- a/packages/frontend/src/components/projects/project/overview/Activity/AuctionCard.tsx +++ b/packages/frontend/src/components/projects/project/overview/Activity/AuctionCard.tsx @@ -134,7 +134,7 @@ export const AuctionCard = ({ project }: { project: Project }) => { size="xs" type={fundsStatus ? 'positive' : 'emphasized'} > - {fundsStatus ? 'RELEASED' : 'LOCKED'} + {fundsStatus ? 'RELEASED' : 'WAITING'}