fix(ui): initial image layers always ignored

Whoops!
This commit is contained in:
psychedelicious 2024-05-24 06:40:48 +10:00
parent 88025d32c2
commit 46a90ca402

View File

@ -497,9 +497,8 @@ const isValidLayer = (layer: Layer, base: BaseModelType) => {
return isValidIPAdapter(layer.ipAdapter, base); return isValidIPAdapter(layer.ipAdapter, base);
} }
if (isInitialImageLayer(layer)) { if (isInitialImageLayer(layer)) {
if (!layer.image) { const hasImage = Boolean(layer.image);
return false; return hasImage;
}
} }
if (isRegionalGuidanceLayer(layer)) { if (isRegionalGuidanceLayer(layer)) {
const hasTextPrompt = Boolean(layer.positivePrompt || layer.negativePrompt); const hasTextPrompt = Boolean(layer.positivePrompt || layer.negativePrompt);