commit 1c83646212b482a2d37fbcba82d0455b6f07cab7 parent a402350cda13f6da7508b507af568b5cf66bb4a6 Author: Simon Kornblith <simon@simonster.com> Date: Thu, 16 Feb 2012 14:22:50 -0500 Avoid throwing if attempt to catch startup errors somehow fails? Diffstat:
| M | chrome/content/zotero/xpcom/zotero.js | | | 10 | +++++++--- |
1 file changed, 7 insertions(+), 3 deletions(-)
diff --git a/chrome/content/zotero/xpcom/zotero.js b/chrome/content/zotero/xpcom/zotero.js @@ -434,9 +434,13 @@ const ZOTERO_CONFIG = { var cs = Components.classes["@mozilla.org/consoleservice;1"]. getService(Components.interfaces.nsIConsoleService); // Get startup errors - var messages = {}; - cs.getMessageArray(messages, {}); - _startupErrors = [msg for each(msg in messages.value) if(_shouldKeepError(msg))]; + try { + var messages = {}; + cs.getMessageArray(messages, {}); + _startupErrors = [msg for each(msg in messages.value) if(_shouldKeepError(msg))]; + } catch(e) { + Zotero.logError(e); + } // Register error observer cs.registerListener(ConsoleListener);