File tree Expand file tree Collapse file tree 1 file changed +11
-4
lines changed Expand file tree Collapse file tree 1 file changed +11
-4
lines changed Original file line number Diff line number Diff line change @@ -945,11 +945,18 @@ window.os_detect.getVersion = function(){
945
945
if ( ! ua_version ) {
946
946
// The ScriptEngine functions failed us, try some object detection
947
947
if ( document . documentElement && ( typeof document . documentElement . style . maxHeight ) != "undefined" ) {
948
- // IE 10 detection using nodeName
948
+ // IE 11 detection, see: http://msdn.microsoft.com/en-us/library/ie/bg182625(v=vs.85).aspx
949
949
try {
950
- var badNode = document . createElement && document . createElement ( "badname" ) ;
951
- if ( badNode && badNode . nodeName === "BADNAME" ) { ua_version = "10.0" ; }
952
- } catch ( e ) { }
950
+ if ( document . __proto__ != undefined ) { ua_version = "11.0" ; }
951
+ } catch ( e ) { }
952
+
953
+ // IE 10 detection using nodeName
954
+ if ( ! ua_version ) {
955
+ try {
956
+ var badNode = document . createElement && document . createElement ( "badname" ) ;
957
+ if ( badNode && badNode . nodeName === "BADNAME" ) { ua_version = "10.0" ; }
958
+ } catch ( e ) { }
959
+ }
953
960
954
961
// IE 9 detection based on a "Object doesn't support property or method" error
955
962
if ( ! ua_version ) {
You can’t perform that action at this time.
0 commit comments