summaryrefslogtreecommitdiffstats
path: root/services/sync/modules/engines
diff options
context:
space:
mode:
authorwolfbeast <mcwerewolf@gmail.com>2018-10-24 14:13:44 +0200
committerwolfbeast <mcwerewolf@gmail.com>2018-10-24 14:13:44 +0200
commit768a1b94576f6a9da284fdb69b9fb1d3354c8f5d (patch)
treed6509c2c36084799a546257d0b8946014eb49e13 /services/sync/modules/engines
parent26412bcab4723d44bc0eb22d7c858e85a84910d5 (diff)
downloadUXP-768a1b94576f6a9da284fdb69b9fb1d3354c8f5d.tar
UXP-768a1b94576f6a9da284fdb69b9fb1d3354c8f5d.tar.gz
UXP-768a1b94576f6a9da284fdb69b9fb1d3354c8f5d.tar.lz
UXP-768a1b94576f6a9da284fdb69b9fb1d3354c8f5d.tar.xz
UXP-768a1b94576f6a9da284fdb69b9fb1d3354c8f5d.zip
Pass exceptions directly to logger.
Diffstat (limited to 'services/sync/modules/engines')
-rw-r--r--services/sync/modules/engines/bookmarks.js13
-rw-r--r--services/sync/modules/engines/passwords.js7
2 files changed, 8 insertions, 12 deletions
diff --git a/services/sync/modules/engines/bookmarks.js b/services/sync/modules/engines/bookmarks.js
index 42d91f57e..41283c06d 100644
--- a/services/sync/modules/engines/bookmarks.js
+++ b/services/sync/modules/engines/bookmarks.js
@@ -373,8 +373,7 @@ BookmarksEngine.prototype = {
// Failure to create a backup is somewhat bad, but probably not bad
// enough to prevent syncing of bookmarks - so just log the error and
// continue.
- this._log.warn("Got exception \"" + Utils.exceptionStr(ex) +
- "\" backing up bookmarks, but continuing with sync.");
+ this._log.warn("Got exception backing up bookmarks, but continuing with sync.", ex);
cb();
}
);
@@ -389,9 +388,8 @@ BookmarksEngine.prototype = {
try {
guidMap = this._buildGUIDMap();
} catch (ex) {
- this._log.warn("Got exception \"" + Utils.exceptionStr(ex) +
- "\" building GUID map." +
- " Skipping all other incoming items.");
+ this._log.warn("Got exception building GUID map." +
+ " Skipping all other incoming items.", ex);
throw {code: Engine.prototype.eEngineAbortApplyIncoming,
cause: ex};
}
@@ -637,7 +635,7 @@ BookmarksStore.prototype = {
return true;
}
} catch(ex) {
- this._log.debug("Failed to reparent item. " + Utils.exceptionStr(ex));
+ this._log.debug("Failed to reparent item. ", ex);
}
return false;
},
@@ -1265,8 +1263,7 @@ BookmarksStore.prototype = {
let u = PlacesUtils.bookmarks.getBookmarkURI(itemID);
this._tagURI(u, tags);
} catch (e) {
- this._log.warn("Got exception fetching URI for " + itemID + ": not tagging. " +
- Utils.exceptionStr(e));
+ this._log.warn("Got exception fetching URI for " + itemID + ": not tagging. ", e);
// I guess it doesn't have a URI. Don't try to tag it.
return;
diff --git a/services/sync/modules/engines/passwords.js b/services/sync/modules/engines/passwords.js
index 2837b6a10..0ccd2e7b0 100644
--- a/services/sync/modules/engines/passwords.js
+++ b/services/sync/modules/engines/passwords.js
@@ -67,7 +67,7 @@ PasswordEngine.prototype = {
Svc.Prefs.set("deletePwdFxA", true);
Svc.Prefs.reset("deletePwd"); // The old prefname we previously used.
} catch (ex) {
- this._log.debug("Password deletes failed: " + Utils.exceptionStr(ex));
+ this._log.debug("Password deletes failed: ", ex);
}
}
},
@@ -213,7 +213,7 @@ PasswordStore.prototype = {
Services.logins.addLogin(login);
} catch(ex) {
this._log.debug("Adding record " + record.id +
- " resulted in exception " + Utils.exceptionStr(ex));
+ " resulted in exception ", ex);
}
},
@@ -246,8 +246,7 @@ PasswordStore.prototype = {
Services.logins.modifyLogin(loginItem, newinfo);
} catch(ex) {
this._log.debug("Modifying record " + record.id +
- " resulted in exception " + Utils.exceptionStr(ex) +
- ". Not modifying.");
+ " resulted in exception. Not modifying.", ex);
}
},