OHIF-125: Fix Exception caused by Cornerstone Tools when sending empty viewports and/or not DOM elements to its functions

This commit is contained in:
Eloízio Salgado committed 2016-11-04 10:31:54 -02:00
1 parent 7d199ab462
commit dfcc64d2ca
4 files changed
+35 -25

No files matched your search

+2 -1
View File
@@ -145,7 +145,8 @@ isPlaying = () => {
// Get the viewport element and its current playClip tool state
const element = getActiveViewportElement();
if (!element) {
// Empty Elements throws cornerstore exception
if (!element || !$(element).find('canvas').length) {
return;
}