From 77174854e5118b99ab1fd6a11c3ef1eaefef984a Mon Sep 17 00:00:00 2001 From: yuexdang <56034408+yuexdang@users.noreply.github.com> Date: Tue, 4 Apr 2023 22:31:47 +0800 Subject: [PATCH] Update main.py --- main.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main.py b/main.py index 4d19243..75e3817 100644 --- a/main.py +++ b/main.py @@ -321,7 +321,7 @@ async def dj_imagine(ctx, prompt: str, try: print(str(image)) - if image.url and "http" in image.url: + if image and image.url and "http" in image.url: prompt = prompt + image.url + " " if imageratio > 0: prompt = prompt + "--iw {} ".format(round(((imageratio + 5) * 0.1), 1))