From 07b8d5640160e5b18a283feb8198994264935e1a Mon Sep 17 00:00:00 2001 From: Dan Stillman Date: Sat, 1 Feb 2014 03:14:43 -0500 Subject: [PATCH] Fix (caught) error accessing this.decoder due to private method call Follow-up to #440 --- chrome/content/zotero/xpcom/fulltext.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/chrome/content/zotero/xpcom/fulltext.js b/chrome/content/zotero/xpcom/fulltext.js index 207813d13..56f859536 100644 --- a/chrome/content/zotero/xpcom/fulltext.js +++ b/chrome/content/zotero/xpcom/fulltext.js @@ -54,7 +54,6 @@ Zotero.Fulltext = new function(){ this.clearCacheFiles = clearCacheFiles; //this.clearItemContent = clearItemContent; this.purgeUnusedWords = purgeUnusedWords; - this.semanticSplitter = semanticSplitter; this.__defineGetter__("pdfToolsDownloadBaseURL", function() { return 'http://www.zotero.org/download/xpdf/'; }); this.__defineGetter__("pdfToolsName", function() { return 'Xpdf'; }); @@ -279,7 +278,7 @@ Zotero.Fulltext = new function(){ try { Zotero.UnresponsiveScriptIndicator.disable(); - var words = semanticSplitter(text, charset); + var words = this.semanticSplitter(text, charset); Zotero.DB.beginTransaction(); @@ -1525,7 +1524,7 @@ Zotero.Fulltext = new function(){ } - function semanticSplitter(text, charset){ + this.semanticSplitter = function (text, charset) { if (!text){ Zotero.debug('No text to index'); return; @@ -1536,6 +1535,7 @@ Zotero.Fulltext = new function(){ text = this.decoder.convertStringToUTF8(text, charset, true); } } catch (err) { + Zotero.debug("Error converting from charset " + charset, 1); Zotero.debug(err, 1); }