Mercurial > cosocket
diff media/js/openwebchat.js @ 93:3be28af79baf
Fixed a really bad bug in timeout detection.
author | Atul Varma <varmaa@toolness.com> |
---|---|
date | Fri, 01 May 2009 18:53:07 -0700 |
parents | 1414765e0929 |
children |
line wrap: on
line diff
--- a/media/js/openwebchat.js Sat May 02 01:04:30 2009 +0000 +++ b/media/js/openwebchat.js Fri May 01 18:53:07 2009 -0700 @@ -90,10 +90,8 @@ dataType: 'json', timeout: self.LISTEN_TIMEOUT, error: function(xhr, textStatus, errorThrown) { - if (textStatus == "timeout" || - textStatus == "parsererror") - // Start another long poll ('parsererror' just means - // our content length was 0, which isn't valid JSON). + if (textStatus == "timeout") + // Start another long poll. self.listenForMessages(options); else options.onError([textStatus, errorThrown]);