SockJS client doesn't need to disable heartbeats

Now that the server disables heartbeats for SockJS on its end,
there is no need for the client to do it and we can use the STOMP
library's default.
This commit is contained in:
Loïc Hoguin 2015-11-26 11:24:00 +01:00
parent 77762f2db8
commit 55fff41832
3 changed files with 0 additions and 17 deletions

View File

@ -115,12 +115,6 @@ if (location.search == '?ws') {
}
var client = Stomp.over(ws);
// SockJS does not support heart-beat: disable heart-beats
if (location.search != '?ws') {
client.heartbeat.outgoing = 0;
client.heartbeat.incoming = 0;
}
client.debug = function() {
if (window.console && console.log && console.log.apply) {
console.log.apply(console, arguments);

View File

@ -87,11 +87,6 @@
}
var client = Stomp.over(ws);
// SockJS does not support heart-beat: disable heart-beats
if (location.search != '?ws') {
client.heartbeat.outgoing = 0;
client.heartbeat.incoming = 0;
}
client.debug = pipe('#second');
var print_first = pipe('#first', function(data) {

View File

@ -70,12 +70,6 @@
}
var client = Stomp.over(ws);
// SockJS does not support heart-beat: disable heart-beats
if (location.search != '?ws') {
client.heartbeat.incoming = 0;
client.heartbeat.outgoing = 0;
}
client.debug = function(e) {
$('#second div').append($("<code>").text(e));
};