commit aa7c1b6fd62637e5fa3e92a3dde5cc77bd132124
parent 492a0d1cd6e0453367362d874267c79298941e6b
Author: Dan Stillman <dstillman@zotero.org>
Date: Tue, 31 Mar 2015 15:30:29 -0400
Merge pull request #694 from aurimasv/translation-log
More verbose logging for translation
Diffstat:
1 file changed, 10 insertions(+), 2 deletions(-)
diff --git a/chrome/content/zotero/xpcom/translation/translate.js b/chrome/content/zotero/xpcom/translation/translate.js
@@ -1505,8 +1505,15 @@ Zotero.Translate.Base.prototype = {
* Called when all translators have been collected for detection
*/
"_detectTranslatorsCollected":function() {
- Zotero.debug("Translate: All translator detect calls and RPC calls complete");
+ Zotero.debug("Translate: All translator detect calls and RPC calls complete:");
this._foundTranslators.sort(function(a, b) { return a.priority-b.priority });
+ if (this._foundTranslators.length) {
+ this._foundTranslators.forEach(function(t) {
+ Zotero.debug("\t" + t.label + ": " + t.priority);
+ });
+ } else {
+ Zotero.debug("\tNo suitable translators found");
+ }
this._runHandler("translators", this._foundTranslators);
},
@@ -1528,7 +1535,8 @@ Zotero.Translate.Base.prototype = {
this._aborted = false;
this.saveQueue = [];
- Zotero.debug("Translate: Parsing code for "+translator.label, 4);
+ Zotero.debug("Translate: Parsing code for " + translator.label + " "
+ + "(" + translator.translatorID + ", " + translator.lastUpdated + ")", 4);
try {
this._sandboxManager.eval("var exports = {}, ZOTERO_TRANSLATOR_INFO = "+translator.code,