Merge pull request #12814 from AUTOMATIC1111/non-local-condition

non-local condition
This commit is contained in:
AUTOMATIC1111 2023-08-27 21:29:48 +03:00
parent d0d5075914
commit bfc5c08109
2 changed files with 2 additions and 2 deletions

View File

@ -15,4 +15,4 @@ else:
cmd_opts, _ = parser.parse_known_args()
cmd_opts.disable_extension_access = (cmd_opts.share or cmd_opts.listen or cmd_opts.server_name) and not cmd_opts.enable_insecure_extension_access
cmd_opts.disable_extension_access = any([cmd_opts.share, cmd_opts.listen, cmd_opts.ngrok, cmd_opts.server_name]) and not cmd_opts.enable_insecure_extension_access

View File

@ -74,7 +74,7 @@ def webui():
if shared.opts.auto_launch_browser == "Remote" or cmd_opts.autolaunch:
auto_launch_browser = True
elif shared.opts.auto_launch_browser == "Local":
auto_launch_browser = not any([cmd_opts.listen, cmd_opts.share, cmd_opts.ngrok])
auto_launch_browser = not any([cmd_opts.listen, cmd_opts.share, cmd_opts.ngrok, cmd_opts.server_name])
app, local_url, share_url = shared.demo.launch(
share=cmd_opts.share,