diff --git a/lib/client.js b/lib/client.js index ef36c851b..0c7329ae5 100644 --- a/lib/client.js +++ b/lib/client.js @@ -1206,6 +1206,7 @@ function doInitialSync(client, historyLen) { client.emit("syncComplete"); _pollForEvents(client); }, function(err) { + console.error("/initialSync error: %s", err); client.emit("syncError", err); // TODO: Retries. }); @@ -1254,6 +1255,7 @@ function _pollForEvents(client) { var discardResult = false; var timeoutObj = setTimeout(function() { discardResult = true; + console.error("/events request timed out."); _pollForEvents(client); }, 40000); @@ -1330,6 +1332,7 @@ function _pollForEvents(client) { } _pollForEvents(self); }, function(err) { + console.error("/events error: %s", JSON.stringify(err)); if (discardResult) { return; }