- Restore error icon if WebDAV verification fails during sync and settings are filled in

- Display slightly more helpful message on unknown error
- Missing file from previous commit
This commit is contained in:
Dan Stillman 2009-09-23 06:59:43 +00:00
parent b6964dc00f
commit e239b69d76
3 changed files with 8 additions and 3 deletions

View file

@ -99,7 +99,8 @@ Zotero.Sync.Storage = new function () {
}
else {
Zotero.debug(_session.name + " verification failed");
_callbacks.onSkip();
_callbacks.onError(_session.name + " verification failed. Verify your "
+ "WebDAV settings in the Sync pane of the Zotero preferences.");
}
}

View file

@ -138,9 +138,9 @@ Zotero.Sync.Storage.Session.prototype.checkServer = function (callback) {
}
}
Zotero.Sync.Storage.Session.prototype.checkServerCallback = function (uri, status, authRequired, window, skipSuccessMessage) {
Zotero.Sync.Storage.Session.prototype.checkServerCallback = function (uri, status, authRequired, window, skipSuccessMessage, error) {
try {
return this._session.checkServerCallback(uri, status, authRequired, window, skipSuccessMessage);
return this._session.checkServerCallback(uri, status, authRequired, window, skipSuccessMessage, error);
}
catch (e) {
this.onError(e);

View file

@ -1027,6 +1027,10 @@ Zotero.Sync.Storage.Session.WebDAV.prototype.checkServerCallback = function (uri
});
return false;
case Zotero.Sync.Storage.ERROR_UNKNOWN:
var errorMessage = "An unknown error occurred. Check your WebDAV settings and server configuration.";
break;
}
if (!skipSuccessMessage) {