From 4fc9dc04cf02440e51d635f5c95e5392f79416a1 Mon Sep 17 00:00:00 2001 From: Hidde Beydals Date: Mon, 16 Dec 2024 23:11:40 +0100 Subject: [PATCH] fix(ui): type issue, vars cannot be optional Co-authored-by: Mayursinh Sarvaiya Signed-off-by: Hidde Beydals --- ui/src/features/stage/create-stage.tsx | 6 ++++-- .../use-promotion-wizard-steps-state.ts | 3 ++- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/ui/src/features/stage/create-stage.tsx b/ui/src/features/stage/create-stage.tsx index 1bebcc210..c01ab74ff 100644 --- a/ui/src/features/stage/create-stage.tsx +++ b/ui/src/features/stage/create-stage.tsx @@ -123,7 +123,8 @@ export const CreateStage = ({ promotionWizardStepsState.state?.map((step) => ({ uses: step?.identifier, as: step?.as, - config: step?.state + config: step?.state, + vars: [] })) ); setValue('value', unmarshalled); @@ -174,7 +175,8 @@ export const CreateStage = ({ promotionWizardStepsState.state?.map((step) => ({ uses: step?.identifier, as: step?.as, - config: step?.state + config: step?.state, + vars: [] })) ) ); diff --git a/ui/src/features/stage/promotion-steps-wizard/use-promotion-wizard-steps-state.ts b/ui/src/features/stage/promotion-steps-wizard/use-promotion-wizard-steps-state.ts index fb0a93d44..b3f1d1c81 100644 --- a/ui/src/features/stage/promotion-steps-wizard/use-promotion-wizard-steps-state.ts +++ b/ui/src/features/stage/promotion-steps-wizard/use-promotion-wizard-steps-state.ts @@ -79,7 +79,8 @@ const stateToYAML = (state: RunnerWithConfiguration[]): string => { promotionSteps.push({ uses: step.identifier, config: step.state, - as: step.as + as: step.as, + vars: [] }); }