Skip to main content

Bug Tracker

Side navigation

#1026 closed bug (fixed)

Opened March 06, 2007 05:21PM UTC

Closed March 16, 2007 12:03AM UTC

Last modified June 20, 2007 12:46AM UTC

isFunction with recursive ajax request

Reported by: teemow Owned by:
Priority: major Milestone: 1.1.3
Component: core Version: 1.1.2
Keywords: Cc:
Blocked by: Blocking:

If I use the short version of jQuery.get (second parameter is callback function) recursively, the second request gets an object as get parameter which is the response of the first request.

This is caused by isFunction. It checks typeof fn[0] == 'undefined' which is false in case of the second request.

I found this error in firefox on linux.

To reproduce try this:

callme = function(response, callback){
    var fn = function(response){
    $.getJSON('/test/', fn);

callme({empty:true}, function(response){
    callme(response, function(){

The second request looks like this:

GET http://localhost/test/?prototype=%5Bobject%20Object%5D
Attachments (0)
Change History (1)

Changed March 16, 2007 12:03AM UTC by john comment:1

component: ajaxcore
resolution: → fixed
status: newclosed

Fixed in SVN rev [1535].