diff --git a/platypush/backend/http/static/js/application.js b/platypush/backend/http/static/js/application.js index b2562c2b..c61ef289 100644 --- a/platypush/backend/http/static/js/application.js +++ b/platypush/backend/http/static/js/application.js @@ -33,7 +33,8 @@ $(document).ready(function() { console.log('Websocket closed, code: ' + event.code); websocketReconnectInterval = setInterval(function() { initWebsocket(); - }, 5000); + }, event.code == 1000 ? 10 : 5000); // Reconnect immediately in case of normal websocket closure + // otherwise wait 5 seconds }; };