fixed issue with automatic start causing it to add interactions repeatedly

This commit is contained in:
csawatzky 2026-01-06 16:32:17 -06:00
parent 8ec08b0c36
commit a225f02795
2 changed files with 24 additions and 21 deletions

View file

@ -436,7 +436,9 @@ if (!selectedDevice) return;
}
stage1.steps.push(newStep);
});
stages.push(stage1)
if(stage1.steps.length > 0){
stages.push(stage1)
}
//stage two is to add the new interactions
let stage2: Stage = {
title: "Add New Interactions",
@ -447,7 +449,9 @@ if (!selectedDevice) return;
}
]
}
stages.push(stage2)
if(stage2.steps.length > 0){
stages.push(stage2)
}
//stage three is to update the controller components
let stage3: Stage = {
@ -463,7 +467,9 @@ if (!selectedDevice) return;
stage3.steps.push(newStep)
})
})
stages.push(stage3)
if(stage3.steps.length > 0){
stages.push(stage3)
}
//set those stages to a state variable
setPromiseStages(stages)
}
@ -721,7 +727,7 @@ if (!selectedDevice) return;
<Box>
<PromiseProgress
stages={promiseStages}
automaticStart
description="These are the changes that will occur in order to change your bin mode with the given options. Press start to begin."
failFast
onStart={() => {
startChange()