diff options
author | Billy Cao <aliencaocao@gmail.com> | 2022-11-03 05:08:11 +0000 |
---|---|---|
committer | Billy Cao <aliencaocao@gmail.com> | 2022-11-03 05:08:11 +0000 |
commit | fb1374791bf4b4c9b49de5378f29b12fdabcac97 (patch) | |
tree | 8454091ab41776720b3ba02f64a55488593b9487 | |
parent | 1a4ff2de6a835cd8cc1590bbc1a8dedb5ad37e5b (diff) | |
download | stable-diffusion-webui-gfx803-fb1374791bf4b4c9b49de5378f29b12fdabcac97.tar.gz stable-diffusion-webui-gfx803-fb1374791bf4b4c9b49de5378f29b12fdabcac97.tar.bz2 stable-diffusion-webui-gfx803-fb1374791bf4b4c9b49de5378f29b12fdabcac97.zip |
Fix --nowebui argument being ineffective
-rw-r--r-- | launch.py | 11 |
1 files changed, 7 insertions, 4 deletions
@@ -217,12 +217,15 @@ def tests(argv): proc.kill()
-def start_webui():
- print(f"Launching Web UI with arguments: {' '.join(sys.argv[1:])}")
+def start():
+ print(f"Launching {'API server' if '--nowebui' in sys.argv else 'Web UI'} with arguments: {' '.join(sys.argv[1:])}")
import webui
- webui.webui()
+ if '--nowebui' in sys.argv:
+ webui.api_only()
+ else:
+ webui.webui()
if __name__ == "__main__":
prepare_enviroment()
- start_webui()
+ start()
|