mirror of
https://github.com/AUTOMATIC1111/stable-diffusion-webui.git
synced 2025-12-06 02:30:30 -08:00
Replace state.need_restart with state.server_command + replace poll loop with signal
This commit is contained in:
parent
4b07f2f584
commit
85b4f89926
4 changed files with 68 additions and 26 deletions
|
|
@ -52,9 +52,7 @@ def apply_and_restart(disable_list, update_list, disable_all):
|
|||
shared.opts.disabled_extensions = disabled
|
||||
shared.opts.disable_all_extensions = disable_all
|
||||
shared.opts.save(shared.config_filename)
|
||||
|
||||
shared.state.interrupt()
|
||||
shared.state.need_restart = True
|
||||
shared.state.request_restart()
|
||||
|
||||
|
||||
def save_config_state(name):
|
||||
|
|
@ -92,8 +90,7 @@ def restore_config_state(confirmed, config_state_name, restore_type):
|
|||
if restore_type == "webui" or restore_type == "both":
|
||||
config_states.restore_webui_config(config_state)
|
||||
|
||||
shared.state.interrupt()
|
||||
shared.state.need_restart = True
|
||||
shared.state.request_restart()
|
||||
|
||||
return ""
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue