Better logging for getAsync() non-integer errors

This commit is contained in:
Dan Stillman 2017-06-08 14:10:15 -04:00
parent 0495f2920a
commit 8913178cf2

View file

@ -175,7 +175,8 @@ Zotero.DataObjects.prototype.getAsync = Zotero.Promise.coroutine(function* (ids,
if (!Number.isInteger(id)) {
// TEMP: Re-enable test when removed
Zotero.logError(`${this._ZDO_object} ID '${id}' is not an integer (${typeof id})`);
let e = new Error(`${this._ZDO_object} ID '${id}' is not an integer (${typeof id})`);
Zotero.logError(e);
id = parseInt(id);
//throw new Error(`${this._ZDO_object} ID '${id}' is not an integer (${typeof id})`);
}