fix: handle undefined instance object (#3042)
Some DisplaySets don't have a `instance` property, thus throwing an error at this location. This change fixes this issue.
This commit is contained in:
1 parent
bbd962f0b4
commit
71d736067d
1 file changed
+1
-3
@@ -1332,9 +1332,7 @@ class SegmentationService {
|
|||||||
segDisplaySetInstanceUID
|
segDisplaySetInstanceUID
|
||||||
);
|
);
|
||||||
|
|
||||||
const {
|
const segFrameOfReferenceUID = segDisplaySet.instance?.FrameOfReferenceUID;
|
||||||
FrameOfReferenceUID: segFrameOfReferenceUID,
|
|
||||||
} = segDisplaySet.instance;
|
|
||||||
|
|
||||||
viewportDisplaySetInstanceUIDs.forEach(displaySetInstanceUID => {
|
viewportDisplaySetInstanceUIDs.forEach(displaySetInstanceUID => {
|
||||||
// check if the displaySet is sharing the same frameOfReferenceUID
|
// check if the displaySet is sharing the same frameOfReferenceUID
|
||||||
|
|||||||
Reference in new issue
Block a user