www

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

commit a71926da26257b1b864a3898d95ef7cbaa67ce23
parent a55677637bc50dba0b759e838f55113c92342e60
Author: Dan Stillman <dstillman@zotero.org>
Date:   Fri, 13 Nov 2009 04:14:27 +0000

Restore JSON.parse() calls that were overwritten


Diffstat:
Mtranslators/ARTstor.js | 4++--
Mtranslators/National Library of Australia (new catalog).js | 5++---
2 files changed, 4 insertions(+), 5 deletions(-)

diff --git a/translators/ARTstor.js b/translators/ARTstor.js @@ -8,7 +8,7 @@ "maxVersion":"", "priority":100, "inRepository":true, - "lastUpdated":"2009-02-08 22:10:00" + "lastUpdated":"2009-11-13 04:15:00" } function detectWeb(doc, url) { @@ -133,7 +133,7 @@ function scrape(doc, url){ } //this gets called when an object is selected in the dialog box, fires off a get on the service url Zotero.Utilities.HTTP.doGet(urls, function(text) { - json = eval("(" + text + ")"); + var json = JSON.parse(text); var newArticle = new Zotero.Item('artwork'); for (var i=0; i<json.metaData.length; i++) { child = json.metaData[i]; diff --git a/translators/National Library of Australia (new catalog).js b/translators/National Library of Australia (new catalog).js @@ -8,7 +8,7 @@ "maxVersion":"", "priority":100, "inRepository":true, - "lastUpdated":"2009-06-04 00:00:00" + "lastUpdated":"2009-11-13 04:15:00" } function detectWeb(doc, url) { @@ -60,8 +60,7 @@ function computeFormat(format){ } function load_item(responseText, url, format) { - - var metadata = eval("(" + Zotero.Utilities.trimInternal(responseText) + ")"); + var metadata = JSON.parse(Zotero.Utilities.trimInternal(responseText)); var bibid = url.match("^.*\/Record/([0-9]+)")[1]; var newItem = new Zotero.Item(format[bibid]);