diff options
author | AUTOMATIC1111 <16777216c@gmail.com> | 2023-08-22 04:30:25 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-08-22 04:30:25 +0000 |
commit | 7da73cbcca69c3f311f829f5ac0b2ef88f3b963e (patch) | |
tree | cbc35adf9f5b6859271934aa8e15ae5889b3781e /modules/ui_tempdir.py | |
parent | 953c3eab7b3b952f7e96d728413a531d7fb521a2 (diff) | |
parent | 299b8096bc19c8a619fbeef735cb90544350243c (diff) | |
download | stable-diffusion-webui-gfx803-7da73cbcca69c3f311f829f5ac0b2ef88f3b963e.tar.gz stable-diffusion-webui-gfx803-7da73cbcca69c3f311f829f5ac0b2ef88f3b963e.tar.bz2 stable-diffusion-webui-gfx803-7da73cbcca69c3f311f829f5ac0b2ef88f3b963e.zip |
Merge pull request #12717 from brkirch/make-temp-directory
Create Gradio temp directory if necessary
Diffstat (limited to 'modules/ui_tempdir.py')
-rw-r--r-- | modules/ui_tempdir.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/modules/ui_tempdir.py b/modules/ui_tempdir.py index 506017e5..85015db5 100644 --- a/modules/ui_tempdir.py +++ b/modules/ui_tempdir.py @@ -44,6 +44,8 @@ def save_pil_to_file(self, pil_image, dir=None, format="png"): if shared.opts.temp_dir != "":
dir = shared.opts.temp_dir
+ else:
+ os.makedirs(dir, exist_ok=True)
use_metadata = False
metadata = PngImagePlugin.PngInfo()
|