aboutsummaryrefslogtreecommitdiffstats
path: root/modules/generation_parameters_copypaste.py
diff options
context:
space:
mode:
authorAUTOMATIC <16777216c@gmail.com>2023-01-15 20:23:16 +0000
committerAUTOMATIC <16777216c@gmail.com>2023-01-15 20:23:24 +0000
commit89314e79da21ac71ad3133ccf5ac3e85d4c24052 (patch)
tree0f7d291e55204725672efb608f997247f15dd52b /modules/generation_parameters_copypaste.py
parentfc25af3939f0366f147892a8ae5b9da56495352b (diff)
downloadstable-diffusion-webui-gfx803-89314e79da21ac71ad3133ccf5ac3e85d4c24052.tar.gz
stable-diffusion-webui-gfx803-89314e79da21ac71ad3133ccf5ac3e85d4c24052.tar.bz2
stable-diffusion-webui-gfx803-89314e79da21ac71ad3133ccf5ac3e85d4c24052.zip
fix an error that happens when you send an empty image from txt2img to img2img
Diffstat (limited to 'modules/generation_parameters_copypaste.py')
-rw-r--r--modules/generation_parameters_copypaste.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/modules/generation_parameters_copypaste.py b/modules/generation_parameters_copypaste.py
index 593d99ef..a381ff59 100644
--- a/modules/generation_parameters_copypaste.py
+++ b/modules/generation_parameters_copypaste.py
@@ -37,6 +37,9 @@ def quote(text):
def image_from_url_text(filedata):
+ if filedata is None:
+ return None
+
if type(filedata) == list and len(filedata) > 0 and type(filedata[0]) == dict and filedata[0].get("is_file", False):
filedata = filedata[0]