Restore JSON.parse() calls that were overwritten
This commit is contained in:
parent
a55677637b
commit
a71926da26
2 changed files with 4 additions and 5 deletions
|
@ -8,7 +8,7 @@
|
||||||
"maxVersion":"",
|
"maxVersion":"",
|
||||||
"priority":100,
|
"priority":100,
|
||||||
"inRepository":true,
|
"inRepository":true,
|
||||||
"lastUpdated":"2009-02-08 22:10:00"
|
"lastUpdated":"2009-11-13 04:15:00"
|
||||||
}
|
}
|
||||||
|
|
||||||
function detectWeb(doc, url) {
|
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
|
//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) {
|
Zotero.Utilities.HTTP.doGet(urls, function(text) {
|
||||||
json = eval("(" + text + ")");
|
var json = JSON.parse(text);
|
||||||
var newArticle = new Zotero.Item('artwork');
|
var newArticle = new Zotero.Item('artwork');
|
||||||
for (var i=0; i<json.metaData.length; i++) {
|
for (var i=0; i<json.metaData.length; i++) {
|
||||||
child = json.metaData[i];
|
child = json.metaData[i];
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
"maxVersion":"",
|
"maxVersion":"",
|
||||||
"priority":100,
|
"priority":100,
|
||||||
"inRepository":true,
|
"inRepository":true,
|
||||||
"lastUpdated":"2009-06-04 00:00:00"
|
"lastUpdated":"2009-11-13 04:15:00"
|
||||||
}
|
}
|
||||||
|
|
||||||
function detectWeb(doc, url) {
|
function detectWeb(doc, url) {
|
||||||
|
@ -60,8 +60,7 @@ function computeFormat(format){
|
||||||
}
|
}
|
||||||
|
|
||||||
function load_item(responseText, url, format) {
|
function load_item(responseText, url, format) {
|
||||||
|
var metadata = JSON.parse(Zotero.Utilities.trimInternal(responseText));
|
||||||
var metadata = eval("(" + Zotero.Utilities.trimInternal(responseText) + ")");
|
|
||||||
var bibid = url.match("^.*\/Record/([0-9]+)")[1];
|
var bibid = url.match("^.*\/Record/([0-9]+)")[1];
|
||||||
var newItem = new Zotero.Item(format[bibid]);
|
var newItem = new Zotero.Item(format[bibid]);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue