update expression

Code fails if element.style is undefined.
This commit is contained in:
Tammy DiPrima 2022-04-13 13:33:44 -04:00 committed by GitHub
parent 2d7be96bdf
commit e1b651b66c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1986,7 +1986,7 @@ function OpenSeadragon( options ){
*/ */
setElementPointerEvents: function( element, value ) { setElementPointerEvents: function( element, value ) {
element = $.getElement( element ); element = $.getElement( element );
if ( typeof element.style.pointerEvents !== 'undefined' ) { if (typeof element.style !== 'undefined' && typeof element.style.pointerEvents !== 'undefined' ) {
element.style.pointerEvents = value; element.style.pointerEvents = value;
} }
}, },