Update webui.py

This commit is contained in:
Jonathan 2022-10-17 03:14:53 -04:00 committed by AUTOMATIC1111
parent 9e02812afd
commit f3fe487e63
1 changed files with 1 additions and 4 deletions

View File

@ -100,10 +100,7 @@ def webui():
if cmd_opts.api: if cmd_opts.api:
from modules.api.api import Api from modules.api.api import Api
api = Api(txt2img=modules.txt2img.txt2img, api = Api()
img2img=modules.img2img.img2img,
run_extras=modules.extras.run_extras,
run_pnginfo=modules.extras.run_pnginfo)
api.launch(server_name="0.0.0.0" if cmd_opts.listen else "127.0.0.1", api.launch(server_name="0.0.0.0" if cmd_opts.listen else "127.0.0.1",
port=cmd_opts.port if cmd_opts.port else 7861) port=cmd_opts.port if cmd_opts.port else 7861)