diff --git a/CHANGELOG b/CHANGELOG index d95b16a..ce3d9bf 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,5 +1,7 @@ *SVN* +* Make Object.isArray correctly identify arrays created in another frame. Closes #10374. [pointy, Dean Edwards, Andrew Dupont, Tobie Langel] + * Fixed issue where Element#match failed on attribute selectors with single or double quotes. Closes #10067. [Cezary Okupski, Andrew Dupont] * Add tests for Element#match. [Tobie Langel] diff --git a/src/base.js b/src/base.js index 9884aaf..2d75f32 100644 --- a/src/base.js +++ b/src/base.js @@ -132,7 +132,8 @@ Object.extend(Object, { }, isArray: function(object) { - return object && object.constructor === Array; + return object != null && typeof object == "object" && + 'splice' in object && 'join' in object; }, isHash: function(object) { diff --git a/test/unit/base.html b/test/unit/base.html index 9828428..51c8e95 100644 --- a/test/unit/base.html +++ b/test/unit/base.html @@ -22,7 +22,12 @@