From f48fadd56ba93e1a83cf119db397e081090554f4 Mon Sep 17 00:00:00 2001 From: Martin Edenhofer Date: Thu, 8 Aug 2013 14:20:40 +0200 Subject: [PATCH] Use queue if App.Ajax now. --- .../javascripts/app/lib/app_post/websocket.js.coffee | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/app/assets/javascripts/app/lib/app_post/websocket.js.coffee b/app/assets/javascripts/app/lib/app_post/websocket.js.coffee index ea1d9593e..f2c9a1c03 100644 --- a/app/assets/javascripts/app/lib/app_post/websocket.js.coffee +++ b/app/assets/javascripts/app/lib/app_post/websocket.js.coffee @@ -287,11 +287,9 @@ class _webSocketSingleton extends App.Controller # return if init is already done and not forced return if @_ajaxInitDone && !data.force - # stop init request if new one is started - if @_ajaxInitWorking - @_ajaxInitWorking.abort() # call init request - @_ajaxInitWorking = App.Ajax.request( + App.Ajax.request( + id: 'ws-login' type: 'POST' url: @Config.get('api_path') + '/message_send' data: JSON.stringify({ data: { action: 'login' } }) @@ -304,10 +302,8 @@ class _webSocketSingleton extends App.Controller @_ajaxReceive() @_ajaxSendQueue() @_ajaxInitDone = true - @_ajaxInitWorking = false error: => @_ajaxInitDone = true - @_ajaxInitWorking = false # try reconnect on error after x sec. reconnect = =>