Skip to content

Commit a67d040

Browse files
authored
🐛 Fix txt2img send dimensions (#2591)
1 parent 3101d31 commit a67d040

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

scripts/controlnet_ui/controlnet_ui_group.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,9 @@ def set_component(self, component: gr.components.IOComponent):
111111
"setting_sd_model_checkpoint": "setting_sd_model_checkpoint",
112112
}
113113
elem_id = getattr(component, "elem_id", None)
114-
if elem_id in id_mapping:
114+
# Do not set component if it has already been set.
115+
# https://github.com/Mikubill/sd-webui-controlnet/issues/2587
116+
if elem_id in id_mapping and getattr(self, id_mapping[elem_id]) is None:
115117
setattr(self, id_mapping[elem_id], component)
116118
logger.debug(f"Setting {elem_id}.")
117119
logger.debug(

0 commit comments

Comments
 (0)