]> source.dussan.org Git - jquery.git/commitdiff
Core: Remove special case try/catch in isPlainObject
authorRick Waldron <waldron.rick@gmail.com>
Sun, 2 Feb 2014 20:36:14 +0000 (15:36 -0500)
committerRick Waldron <waldron.rick@gmail.com>
Sun, 2 Feb 2014 20:40:39 +0000 (15:40 -0500)
Fixes #14746

src/core.js

index 6afb97685fe9c8e4712bb71b4880046822fb88b5..67b6e71998fabecb77cd28b5bbf99859322f9d95 100644 (file)
@@ -225,16 +225,8 @@ jQuery.extend({
                        return false;
                }
 
-               // Support: Firefox <20
-               // The try/catch suppresses exceptions thrown when attempting to access
-               // the "constructor" property of certain host objects, ie. |window.location|
-               // https://bugzilla.mozilla.org/show_bug.cgi?id=814622
-               try {
-                       if ( obj.constructor &&
-                                       !hasOwn.call( obj.constructor.prototype, "isPrototypeOf" ) ) {
-                               return false;
-                       }
-               } catch ( e ) {
+               if ( obj.constructor &&
+                               !hasOwn.call( obj.constructor.prototype, "isPrototypeOf" ) ) {
                        return false;
                }