View in #cornerstone3d on Slack
@Julian_Linares: Hello
:skin_tone_3: , whenever I remove viewports from the HTML that is being rendered, I get an error coming from removeEnabledElement.js
, which calls removeEnabledElement(elementDisabledEvt)
and in two nested functions tries to get the enabledElement
by getEnabledElement(element)
(element is provided in elementDisabledEvt.detail). Problem is in my case enabledElement
will always be undefined and the function can not continue, which causes the error. I fixed it by adding if (!enabledElement) return;
right after it tries to get it, but is there a better way to solve this, without having to modify source code?
@Alireza_Sedghi: i guess not, create a PR if that makes sense