From 04660acbd109b8edb26d3391a1629ecf9e130c07 Mon Sep 17 00:00:00 2001 From: Dan Stillman Date: Wed, 22 Jul 2009 08:05:19 +0000 Subject: [PATCH] Don't trigger error in Google Scholar if called with no items (since the PDF recognition process does this) --- translators/Google Scholar.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/translators/Google Scholar.js b/translators/Google Scholar.js index 13e2ff021..b959ec59c 100644 --- a/translators/Google Scholar.js +++ b/translators/Google Scholar.js @@ -8,7 +8,7 @@ "maxVersion":"", "priority":100, "inRepository":true, - "lastUpdated":"2009-07-13 19:15:00" + "lastUpdated":"2009-07-22 08:05:00" } function detectWeb(doc, url) { @@ -47,6 +47,10 @@ function scrape(doc) { i++; } + if (!items.length) { + if(Zotero.done) Zotero.done(true); + return; + } items = Zotero.selectItems(items); if(!items) {