From 6199742986258ec36f18d5f1d191c49df915755f Mon Sep 17 00:00:00 2001 From: Dan Stillman Date: Wed, 19 Nov 2014 03:02:36 -0500 Subject: [PATCH] Make attempt to read from an invalid DB column a fatal error --- chrome/content/zotero/xpcom/db.js | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/chrome/content/zotero/xpcom/db.js b/chrome/content/zotero/xpcom/db.js index f69a6e4212..1cbe994f7a 100644 --- a/chrome/content/zotero/xpcom/db.js +++ b/chrome/content/zotero/xpcom/db.js @@ -701,9 +701,10 @@ Zotero.DBConnection.prototype.queryAsync = function (sql, params, options) { return target.getResultByName(name); } catch (e) { - Zotero.debug((new Error).stack, 2); - Zotero.debug("DB column '" + name + "' not found", 2); - return undefined; + Zotero.debug(e, 1); + var msg = "DB column '" + name + "' not found"; + Zotero.debug(msg, 1); + throw new Error(msg); } } };