mirror of
https://github.com/AUTOMATIC1111/stable-diffusion-webui.git
synced 2025-01-21 05:40:11 +08:00
fix js error at startup
This commit is contained in:
parent
cf08f5b4d2
commit
816390938f
@ -17,7 +17,10 @@ onOptionsChanged(function() {
|
|||||||
if (div.classList.contains('gradio-checkbox')) span = div.querySelector('label span');
|
if (div.classList.contains('gradio-checkbox')) span = div.querySelector('label span');
|
||||||
else if (div.classList.contains('gradio-checkboxgroup')) span = div.querySelector('span').firstChild;
|
else if (div.classList.contains('gradio-checkboxgroup')) span = div.querySelector('span').firstChild;
|
||||||
else if (div.classList.contains('gradio-radio')) span = div.querySelector('span').firstChild;
|
else if (div.classList.contains('gradio-radio')) span = div.querySelector('span').firstChild;
|
||||||
else span = div.querySelector('label span').firstChild;
|
else {
|
||||||
|
var elem = div.querySelector('label span');
|
||||||
|
if(elem) span = elem.firstChild;
|
||||||
|
}
|
||||||
|
|
||||||
if (!span) return;
|
if (!span) return;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user