Fixes #7413; isEmptyObject() check to see if obj passes isPlainObject
[jquery.git] / src / core.js
index 9e1bfc6..c11133f 100644 (file)
@@ -532,6 +532,12 @@ jQuery.extend({
        },
 
        isEmptyObject: function( obj ) {
+
+    // Fixes #7413 Check to see if obj passes isPlainObject
+    if ( !jQuery.isPlainObject( obj ) ) {
+      return false;
+    }
+       
                for ( var name in obj ) {
                        return false;
                }