-
-
Notifications
You must be signed in to change notification settings - Fork 75
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
onConnectInput: Uncaught TypeError: this is undefined #94
Comments
I am on very latest ComfyUI version and I can't reproduce this error. At one point it for some reason stopped working with |
it errors out when I drag out an image output from a node and drop it onto the image input of a GetImageSizeAndCount node. for some reason, that I cannot explain the issue I found happens both in chrome and firefox |
|
that is the ideal value of
it doesn't use apply, if you look at the other function calls being defined before it in the same code, they use apply, for example:
since the onConnectInput doesn't use apply, it ends up passing I can't explain why it doesn't produce an error for you, except maybe your call stack is different? |
I think I should close this, after doing an update the problem is fixed, the reason is fixed is because your node is defined first which reverses the order. before I close this though, I just noticed your code has a similar issue, it does not use |
Yeah I think you are absolutely correct, somehow I missed that, thanks. |
When I try to connect an image output to GetImageSizeAndCount input, I get a javascript error:
I'm looking at the code involved and it is the latest comfyui and kjnodes.
This looks to me to be an error in comfyui, but your change is more recent
https://github.com/comfyanonymous/ComfyUI/blob/93000580261971971ebb12aff03f6bc3ce30a9f2/web/extensions/core/widgetInputs.js#L454
ComfyUI-KJNodes/web/js/jsnodes.js
Line 103 in adb35ee
what is happening is that in comfy's
onConnectInput
,this
is passed as an argument to your function, instead of usingapply
like it does for other function calls.your change from a months ago though, went from using the first parameter
targetSlot
tothis
which is undefined.83095a5
The text was updated successfully, but these errors were encountered: