diff options
author | Todor Prikumov <tono_pr@abv.bg> | 2016-01-26 11:58:34 +0200 |
---|---|---|
committer | Timmy Willison <timmywillisn@gmail.com> | 2016-01-27 11:35:51 -0500 |
commit | 35c314827d8b5b4eb996cf590d8254eea48a3896 (patch) | |
tree | 57e0d2457d49f76b3936d6656ca2019c0e5412ed | |
parent | 1de834672959636da8c06263c3530226b17a84c3 (diff) | |
download | jquery-35c314827d8b5b4eb996cf590d8254eea48a3896.tar.gz jquery-35c314827d8b5b4eb996cf590d8254eea48a3896.zip |
CSS: Make sure elem.ownerDocument.defaultView is not null
Fixes gh-2866
Close gh-2867
-rw-r--r-- | src/css/var/getStyles.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/css/var/getStyles.js b/src/css/var/getStyles.js index 1fa915d58..02a4b8194 100644 --- a/src/css/var/getStyles.js +++ b/src/css/var/getStyles.js @@ -6,7 +6,7 @@ define( function() { // FF meanwhile throws on frame elements through "defaultView.getComputedStyle" var view = elem.ownerDocument.defaultView; - if ( !view.opener ) { + if ( !view || !view.opener ) { view = window; } |