Browse Source

bugfix: Bug fix for the issue where enable/disable of the web extension was not working.

pull/43/head
Dr.Lt.Data 1 year ago
parent
commit
e6919a582a
  1. 7
      README.md
  2. 13
      __init__.py

7
README.md

@ -32,9 +32,10 @@ You can execute ComfyUI by running either `./run_gpu.sh` or `./run_cpu.sh` depen
# Changes # Changes
* **0.17** Support preview method setting feature * **0.17.1** Bug fix for the issue where enable/disable of the web extension was not working.
* **0.14** Support robust update * **0.17** Support preview method setting feature.
* **0.13** Support additional 'pip' section for install spec * **0.14** Support robust update.
* **0.13** Support additional 'pip' section for install spec.
* **0.12** Better installation support for Windows. * **0.12** Better installation support for Windows.
* **0.9** Support keyword search in installer menu. * **0.9** Support keyword search in installer menu.
* **V0.7.1** Bug fix for the issue where updates were not being applied on Windows. * **V0.7.1** Bug fix for the issue where updates were not being applied on Windows.

13
__init__.py

@ -33,7 +33,7 @@ sys.path.append('../..')
from torchvision.datasets.utils import download_url from torchvision.datasets.utils import download_url
# ensure .js # ensure .js
print("### Loading: ComfyUI-Manager (V0.17)") print("### Loading: ComfyUI-Manager (V0.17.1)")
comfy_ui_revision = "Unknown" comfy_ui_revision = "Unknown"
@ -357,7 +357,14 @@ def check_a_custom_node_installed(item, do_fetch=False):
elif item['install_type'] == 'copy' and len(item['files']) == 1: elif item['install_type'] == 'copy' and len(item['files']) == 1:
dir_name = os.path.basename(item['files'][0]) dir_name = os.path.basename(item['files'][0])
base_path = custom_nodes_path if item['files'][0].endswith('.py') else js_path
if item['files'][0].endswith('.py'):
base_path = custom_nodes_path
elif 'js_path' in item:
base_path = os.path.join(js_path, item['js_path'])
else:
base_path = js_path
file_path = os.path.join(base_path, dir_name) file_path = os.path.join(base_path, dir_name)
if os.path.exists(file_path): if os.path.exists(file_path):
item['installed'] = 'True' item['installed'] = 'True'
@ -893,7 +900,7 @@ async def install_custom_node(request):
if install_type == "git-clone": if install_type == "git-clone":
res = gitclone_set_active(json_data['files'], not is_disabled) res = gitclone_set_active(json_data['files'], not is_disabled)
elif install_type == "copy": elif install_type == "copy":
res = copy_set_active(json_data['files'], not is_disabled) res = copy_set_active(json_data['files'], not is_disabled, json_data.get('js_path', None))
if res: if res:
return web.json_response({}, content_type='application/json') return web.json_response({}, content_type='application/json')

Loading…
Cancel
Save