jquery core: improves #3248. Functions are supported by isFunction.

This commit is contained in:
Ariel Flesler 2008-10-29 01:12:27 +00:00
parent 12bb969411
commit 61784e1581

View file

@ -1137,7 +1137,7 @@ jQuery.extend({
if( array != null ){
var i = array.length;
// The window, strings (and functions) also have 'length'
if( i == null || typeof array == 'string' || array.setInterval )
if( i == null || typeof array == 'string' || jQuery.isFunction(array) || array.setInterval )
ret[0] = array;
else
while( i )