diff options
author | Billy Cao <aliencaocao@gmail.com> | 2022-11-27 13:19:47 +0000 |
---|---|---|
committer | Billy Cao <aliencaocao@gmail.com> | 2022-11-27 13:19:47 +0000 |
commit | 06ada734c7f85e5e6e2e6ae78fb873be0222bfd5 (patch) | |
tree | dd94aa18de1091422eb88966f166561d4ec415b4 /modules/api | |
parent | 3cf93de24f90247af33ab9cf743a6eb45308d668 (diff) | |
download | stable-diffusion-webui-gfx803-06ada734c7f85e5e6e2e6ae78fb873be0222bfd5.tar.gz stable-diffusion-webui-gfx803-06ada734c7f85e5e6e2e6ae78fb873be0222bfd5.tar.bz2 stable-diffusion-webui-gfx803-06ada734c7f85e5e6e2e6ae78fb873be0222bfd5.zip |
Prevent warning on sampler_index if sampler_name is being used
Diffstat (limited to 'modules/api')
-rw-r--r-- | modules/api/api.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/modules/api/api.py b/modules/api/api.py index 53980551..2f450fc4 100644 --- a/modules/api/api.py +++ b/modules/api/api.py @@ -117,6 +117,8 @@ class Api: "do_not_save_grid": True } ) + if populate.sampler_name: + populate.sampler_index = None # prevent a warning later on p = StableDiffusionProcessingTxt2Img(**vars(populate)) # Override object param @@ -148,6 +150,8 @@ class Api: "mask": mask } ) + if populate.sampler_name: + populate.sampler_index = None # prevent a warning later on p = StableDiffusionProcessingImg2Img(**vars(populate)) imgs = [] |