From 28267da071fcece8406a5695b767a6c75e7e245a Mon Sep 17 00:00:00 2001 From: "Dr.Lt.Data" Date: Wed, 25 Sep 2024 09:36:06 +0900 Subject: [PATCH] fix: new front compatibilty issue https://github.com/ltdrdata/ComfyUI-Impact-Pack/issues/755 --- js/impact-pack.js | 4 ++-- modules/impact/config.py | 2 +- pyproject.toml | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/js/impact-pack.js b/js/impact-pack.js index c763ec2..f0c57a6 100644 --- a/js/impact-pack.js +++ b/js/impact-pack.js @@ -383,7 +383,7 @@ app.registerExtension({ } let select_slot = this.inputs.find(x => x.name == "select"); - if(this.widgets) { + if(this.widgets?.length) { this.widgets[0].options.max = select_slot?this.outputs.length-1:this.outputs.length; this.widgets[0].value = Math.min(this.widgets[0].value, this.widgets[0].options.max); if(this.widgets[0].options.max > 0 && this.widgets[0].value == 0) @@ -537,7 +537,7 @@ app.registerExtension({ this.addInput(`${input_name}${slot_i}`, this.outputs[0].type); } - if(this.widgets) { + if(this.widgets?.length) { this.widgets[0].options.max = select_slot?this.inputs.length-1:this.inputs.length; this.widgets[0].value = Math.min(this.widgets[0].value, this.widgets[0].options.max); if(this.widgets[0].options.max > 0 && this.widgets[0].value == 0) diff --git a/modules/impact/config.py b/modules/impact/config.py index a400fb9..18fdc8e 100644 --- a/modules/impact/config.py +++ b/modules/impact/config.py @@ -1,7 +1,7 @@ import configparser import os -version_code = [7, 7] +version_code = [7, 7, 1] version = f"V{version_code[0]}.{version_code[1]}" + (f'.{version_code[2]}' if len(version_code) > 2 else '') dependency_version = 22 diff --git a/pyproject.toml b/pyproject.toml index 75087ef..5655eac 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,7 +1,7 @@ [project] name = "comfyui-impact-pack" description = "This extension offers various detector nodes and detailer nodes that allow you to configure a workflow that automatically enhances facial details. And provide iterative upscaler." -version = "7.7" +version = "7.7.1" license = { file = "LICENSE.txt" } dependencies = ["segment-anything", "scikit-image", "piexif", "transformers", "opencv-python-headless", "GitPython", "scipy>=1.11.4"]