aboutsummaryrefslogtreecommitdiffstats
path: root/modules/restart.py
diff options
context:
space:
mode:
authorAUTOMATIC1111 <16777216c@gmail.com>2023-12-14 07:10:43 +0000
committerGitHub <noreply@github.com>2023-12-14 07:10:43 +0000
commit097140ac1a3caf6e3c9980a757d4b52e6a76b789 (patch)
treec31cf29908f94e7f6792b063df4543d6f83b423c /modules/restart.py
parentbda86f0fd9653657c146f7c1128f92771d16ad4e (diff)
parent778a30a95e216f9f7ce0126dbbdb1334afc3d796 (diff)
downloadstable-diffusion-webui-gfx803-097140ac1a3caf6e3c9980a757d4b52e6a76b789.tar.gz
stable-diffusion-webui-gfx803-097140ac1a3caf6e3c9980a757d4b52e6a76b789.tar.bz2
stable-diffusion-webui-gfx803-097140ac1a3caf6e3c9980a757d4b52e6a76b789.zip
Merge branch 'dev' into master
Diffstat (limited to 'modules/restart.py')
-rw-r--r--modules/restart.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/modules/restart.py b/modules/restart.py
index 18eacaf3..2dd6493b 100644
--- a/modules/restart.py
+++ b/modules/restart.py
@@ -14,7 +14,9 @@ def is_restartable() -> bool:
def restart_program() -> None:
"""creates file tmp/restart and immediately stops the process, which webui.bat/webui.sh interpret as a command to start webui again"""
- (Path(script_path) / "tmp" / "restart").touch()
+ tmpdir = Path(script_path) / "tmp"
+ tmpdir.mkdir(parents=True, exist_ok=True)
+ (tmpdir / "restart").touch()
stop_program()