Skip to content

Commit 770107a

Browse files
committed
Fix error in IE8 because Document type is undefined
1 parent 111597c commit 770107a

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

jquery.fullscreen-min.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

jquery.fullscreen.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* @preserve jquery.fullscreen 1.1.2
2+
* @preserve jquery.fullscreen 1.1.3
33
* https://github.com/kayahr/jquery-fullscreen-plugin
44
* Copyright (C) 2012 Klaus Reimer <k@ailis.de>
55
* Licensed under the MIT license
@@ -37,14 +37,14 @@ function fullScreen(state)
3737

3838
// Find the real element and the document (Depends on whether the
3939
// document itself or a HTML element was selected)
40-
if (e instanceof Document)
40+
if (e.ownerDocument)
4141
{
42-
doc = e;
43-
e = doc.documentElement;
42+
doc = e.ownerDocument;
4443
}
4544
else
4645
{
47-
doc = e.ownerDocument;
46+
doc = e;
47+
e = doc.documentElement;
4848
}
4949

5050
// When no state was specified then return the current state.

0 commit comments

Comments
 (0)