diff --git a/source/Ox/js/Type.js b/source/Ox/js/Type.js index 5ddd19af..3dbc45ac 100644 --- a/source/Ox/js/Type.js +++ b/source/Ox/js/Type.js @@ -409,10 +409,12 @@ Ox.typeOf = function(value) { // Internet Explorer 8 returns 'Object' for nodelists, // Internet Explorer 9 returns 'HTMLCollection' for nodelists, // Mobile Safari returns 'DOMWindow' for null and undefined +// Firefox 30+ returns 'window' for window if ( Ox.typeOf((function() { return arguments; }())) != 'arguments' || Ox.typeOf(document.getElementsByTagName('a')) != 'nodelist' || Ox.typeOf(null) != 'null' + || Ox.typeOf(window) != 'global' || Ox.typeOf() != 'undefined' ) { Ox.typeOf = function(value) { @@ -423,6 +425,8 @@ if ( type = 'null'; } else if (value === void 0) { type = 'undefined'; + } else if (value === window) { + type = 'window'; } else if (type == 'object' && typeof value.callee == 'function') { type = 'arguments'; } else if (