Bug Tracker

Ticket #3134: toString.diff

File toString.diff, 538 bytes (added by john, 14 years ago)

Change toString functionality in isFunction

  • src/core.js

     
    615615        // See test/unit/core.js for details concerning this function.
    616616        isFunction: function( fn ) {
    617617                return !!fn && typeof fn != "string" && !fn.nodeName &&
    618                         fn.constructor != Array && /^[\s[]?function/.test( fn + "" );
     618                        fn.constructor != Array && /^[\s[]?function/.test( Object.toString.call(fn) );
    619619        },
    620620
    621621        // check if an element is in a (or is an) XML document