www

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | Submodules | README | LICENSE

commit 746171ab7844e66eed1f3e1f81addd8ab7832a35
parent 12e7b7b851c6d636f46c4ca488a257ea45f23db4
Author: Adomas VenĨkauskas <adomas.ven@gmail.com>
Date:   Mon,  8 May 2017 09:23:53 +0300

Fix doc.prefs.noteType handling with NaN values

Diffstat:
Mchrome/content/zotero/xpcom/integration.js | 7++-----
1 file changed, 2 insertions(+), 5 deletions(-)

diff --git a/chrome/content/zotero/xpcom/integration.js b/chrome/content/zotero/xpcom/integration.js @@ -3137,11 +3137,8 @@ Zotero.Integration.DocumentData.prototype.unserializeXML = function(xmlData) { this.prefs[name] = value; } - try { - this.prefs.noteType = parseInt(this.prefs.noteType); - } catch (e) { - this.prefs.noteType = 0; - } + + this.prefs.noteType = parseInt(this.prefs.noteType) || 0; if (this.prefs["automaticJournalAbbreviations"] === undefined) this.prefs["automaticJournalAbbreviations"] = false; this.zoteroVersion = doc.documentElement.getAttribute("zotero-version"); if (!this.zoteroVersion) this.zoteroVersion = "2.0";