fix bug with handling setCode

This commit is contained in:
Abi Raja 2024-07-30 16:09:02 -04:00
parent aff9352dc0
commit f52ca306a5

View File

@ -189,8 +189,11 @@ function App() {
},
// On set code
(code, variant) => {
if (variant === currentVariantIndex) {
setGeneratedCode(code);
}
setVariant(code, variant);
setGeneratedCode(code);
// TODO: How to deal with variants?
if (params.generationType === "create") {