Fix "function $A" declaration inside of a conditional (confuses IE). Fixes #10882. [Jacco, Andrew Dupont]
This commit is contained in:
parent
c67fe0b2f3
commit
c200c27f48
|
@ -1,5 +1,7 @@
|
|||
*SVN*
|
||||
|
||||
* Fix "function $A" declaration inside of a conditional (confuses IE). Fixes #10882. [Jacco, Andrew Dupont]
|
||||
|
||||
* Fixed selector parsing so that "#foo [bar=baz]" is treated the same way as "#foo *[bar=baz]". Closes #10734. [jlukas, kangax, Andrew Dupont]
|
||||
|
||||
* Fix Element#descendantOf logic in IE. Closes #10413. [martymix, kamil.szot]
|
||||
|
|
|
@ -7,14 +7,14 @@ function $A(iterable) {
|
|||
}
|
||||
|
||||
if (Prototype.Browser.WebKit) {
|
||||
function $A(iterable) {
|
||||
$A = function(iterable) {
|
||||
if (!iterable) return [];
|
||||
if (!(Object.isFunction(iterable) && iterable == '[object NodeList]') &&
|
||||
iterable.toArray) return iterable.toArray();
|
||||
var length = iterable.length || 0, results = new Array(length);
|
||||
while (length--) results[length] = iterable[length];
|
||||
return results;
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
Array.from = $A;
|
||||
|
|
Loading…
Reference in New Issue