fix(ui): fix erroneous vae model display

`react-select` has some weird behaviour where if the value is `undefined`, it shows the last-selected value instead of nothing. Must fall back to `null`
This commit is contained in:
psychedelicious 2024-01-03 09:38:01 +11:00
parent 930de51910
commit 8aeeee4752

View File

@ -65,7 +65,7 @@ export const useGroupedModelInvSelect = <T extends AnyModelConfigEntity>(
.flatMap((o) => o.options)
.find((m) =>
selectedModel ? m.value === getModelId(selectedModel) : false
),
) ?? null,
[options, selectedModel]
);