mirror of
https://github.com/invoke-ai/InvokeAI.git
synced 2026-04-23 03:00:31 -04:00
Fix bugs when switching control layer type. This logic still feels very hacky.
This commit is contained in:
@@ -493,10 +493,10 @@ export const canvasSlice = createSlice({
|
||||
|
||||
case 'control_lora': {
|
||||
if (layer.controlAdapter.type === 'controlnet') {
|
||||
const controlLoraConfig: ControlLoRAConfig = { ...layer.controlAdapter, ...initialControlLoRA };
|
||||
const controlLoraConfig: ControlLoRAConfig = { ...layer.controlAdapter, type: 'control_lora' };
|
||||
layer.controlAdapter = controlLoraConfig;
|
||||
} else if (layer.controlAdapter.type === 't2i_adapter') {
|
||||
const controlLoraConfig: ControlLoRAConfig = { ...layer.controlAdapter, ...initialControlLoRA };
|
||||
const controlLoraConfig: ControlLoRAConfig = { ...layer.controlAdapter, type: 'control_lora' };
|
||||
layer.controlAdapter = controlLoraConfig;
|
||||
}
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user