Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
("Fallback transport from Websocket to Comet issue with Chrome")
  • Loading branch information
jfarcand committed Oct 1, 2010
1 parent 98908b4 commit 2cd3538
Showing 1 changed file with 1 addition and 18 deletions.
19 changes: 1 addition & 18 deletions modules/jquery/src/main/webapp/jquery/jquery.atmosphere.js
Expand Up @@ -214,7 +214,7 @@ jQuery.atmosphere = function()
}
}
request.lastIndex = ajaxRequest.responseText.length;

if (junkForWebkit) return;
} else {
response.responseBody = ajaxRequest.responseText;
}
Expand All @@ -239,7 +239,6 @@ jQuery.atmosphere = function()
response.state = "messagePublished";
}

if (junkForWebkit) return;
jQuery.atmosphere.invokeCallback(response);
}
}
Expand Down Expand Up @@ -363,14 +362,6 @@ jQuery.atmosphere = function()
jQuery.atmosphere.request = request;
jQuery.atmosphere.executeRequest();

// Repost the data.
jQuery.atmosphere.request.suspend = false;
jQuery.atmosphere.request.method = 'POST';
jQuery.atmosphere.request.data = data;
jQuery.atmosphere.response.state = 'messageReceived';
jQuery.atmosphere.response.transport = request.fallbackTransport;
jQuery.atmosphere.publish(url, null, jQuery.atmosphere.request);

ws.onclose = function(message) {
}
ws.close();
Expand Down Expand Up @@ -413,14 +404,6 @@ jQuery.atmosphere = function()
request.transport = request.fallbackTransport;
jQuery.atmosphere.request = request;
jQuery.atmosphere.executeRequest();

// Repost the data.
jQuery.atmosphere.request.suspend = false;
jQuery.atmosphere.request.method = 'POST';
jQuery.atmosphere.request.data = data;
jQuery.atmosphere.response.state = 'messageReceived';
jQuery.atmosphere.response.transport = request.fallbackTransport;
jQuery.atmosphere.publish(url, null, jQuery.atmosphere.request);
} else {
jQuery.atmosphere.response.state = 'closed';
jQuery.atmosphere.invokeCallback(jQuery.atmosphere.response);
Expand Down

0 comments on commit 2cd3538

Please sign in to comment.