Fix display of sync error icon on error

This commit is contained in:
Dan Stillman 2016-02-25 04:51:55 -05:00
parent aab4fca3ad
commit 6ac35c75c1
2 changed files with 42 additions and 24 deletions

View file

@ -160,7 +160,7 @@ Zotero.Sync.Runner_Module = function (options = {}) {
options.onError(e);
}
else {
this.addError.bind(this);
this.addError(e);
}
}.bind(this),
background: _background,
@ -488,12 +488,7 @@ Zotero.Sync.Runner_Module = function (options = {}) {
Zotero.debug("Sync failed for library " + libraryID);
Zotero.logError(e);
this.checkError(e);
if (options.onError) {
options.onError(e);
}
else {
this.addError(e);
}
options.onError(e);
if (stopOnError || e.fatal) {
Zotero.debug("Stopping on error", 1);
options.caller.stop();
@ -548,12 +543,7 @@ Zotero.Sync.Runner_Module = function (options = {}) {
Zotero.debug("File sync failed for library " + libraryID);
Zotero.logError(e);
this.checkError(e);
if (options.onError) {
options.onError(e);
}
else {
this.addError(e);
}
options.onError(e);
if (stopOnError || e.fatal) {
options.caller.stop();
break;
@ -583,12 +573,7 @@ Zotero.Sync.Runner_Module = function (options = {}) {
Zotero.debug("Full-text sync failed for library " + libraryID);
Zotero.logError(e);
this.checkError(e);
if (options.onError) {
options.onError(e);
}
else {
this.addError(e);
}
options.onError(e);
if (stopOnError || e.fatal) {
options.caller.stop();
break;