Resolve schemaUpdatePromise even if repository returns 500 at startup
If repo.zotero.org returned a 500 during Zotero startup, translators and
styles wouldn't be initialized until a 200 was returned, and various
things that depended on translators or styles wouldn't work in the
meantime. Now a single retry is made after 5 seconds, and if that fails
the promise is resolved regardless.
Regression from dc60e5f840
, which added automatic 5xx retrying to
Zotero.HTTP.request()
This commit is contained in:
parent
da529d0d39
commit
e406e04f5c
1 changed files with 9 additions and 1 deletions
|
@ -1527,7 +1527,15 @@ Zotero.Schema = new function(){
|
|||
var body = 'styles=' + encodeURIComponent(JSON.stringify(styleTimestamps));
|
||||
|
||||
try {
|
||||
var xmlhttp = yield Zotero.HTTP.request("POST", url, { body: body });
|
||||
var xmlhttp = yield Zotero.HTTP.request(
|
||||
"POST",
|
||||
url,
|
||||
{
|
||||
body,
|
||||
errorDelayMax: 5000,
|
||||
errorDelayIntervals: [5000]
|
||||
}
|
||||
);
|
||||
updated = yield _handleRepositoryResponse(xmlhttp, mode);
|
||||
}
|
||||
catch (e) {
|
||||
|
|
Loading…
Add table
Reference in a new issue