From b66a6b9518a4e49a2f2780a5b7aeeb673dc49df4 Mon Sep 17 00:00:00 2001 From: Dan Stillman Date: Sat, 23 Apr 2016 00:58:52 -0400 Subject: [PATCH] Remove old sync throttle code (replaced by Backoff header) --- chrome/content/zotero/xpcom/sync.js | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/chrome/content/zotero/xpcom/sync.js b/chrome/content/zotero/xpcom/sync.js index d67263b52..02bf9bd15 100644 --- a/chrome/content/zotero/xpcom/sync.js +++ b/chrome/content/zotero/xpcom/sync.js @@ -161,23 +161,6 @@ Zotero.Sync.Server = new function () { var firstChild = xmlhttp.responseXML.firstChild.firstChild; - // Temporarily disable auto-sync if instructed by server - if (firstChild.localName == 'throttle') { - Zotero.debug(xmlhttp.responseText); - var delay = first.getAttribute('delay'); - var time = new Date(); - time = time.getTime() + (delay * 1000); - time = new Date(time); - _throttleTimeout = time; - if (delay < 86400000) { - var timeStr = time.toLocaleTimeString(); - } - else { - var timeStr = time.toLocaleString(); - } - _error("Auto-syncing disabled until " + timeStr, false, noReloadOnFailure); - } - if (firstChild.localName == 'error') { // Don't automatically retry 400 errors if (xmlhttp.status >= 400 && xmlhttp.status < 500 && !_invalidSession(xmlhttp)) {