Skip to content

Commit

Permalink
Get to clean BibTeX
Browse files Browse the repository at this point in the history
  • Loading branch information
adam3smith committed Sep 16, 2023
1 parent 62cc27e commit 43f83ec
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions PhilPapers.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"inRepository": true,
"translatorType": 4,
"browserSupport": "gcsibv",
"lastUpdated": "2023-09-10 18:24:30"
"lastUpdated": "2023-09-16 03:26:02"
}

/*
Expand Down Expand Up @@ -86,10 +86,10 @@ async function doWeb(doc, url) {


async function scrape(identifiers, isPhilArchive) {
let baseUrl = isPhilArchive ? "https://philarchive.org" : "https://philpapers.org";

Check failure on line 89 in PhilPapers.js

View workflow job for this annotation

GitHub Actions / Lint, Check, Test

Expected indentation of 1 tab but found 2
for (let id of identifiers) {
let bibUrl = "https://philpapers.org/export.html?__format=bib&eIds=" + id + "&formatName=BibTeX";
let bibText = await requestText(bibUrl);
bibText = bibText.replace(/\n/g, "").match(/<pre class="export">.+<\/pre>/)[0];
let bibUrl = `${baseUrl}/item.pl?eId=${id}&format=bib`;
let bibText = await requestText(bibUrl);

Check failure on line 92 in PhilPapers.js

View workflow job for this annotation

GitHub Actions / Lint, Check, Test

Trailing spaces not allowed
let url = "/rec/" + id;
let translator = Zotero.loadTranslator("import");
translator.setTranslator('9cb70025-a888-4a29-a210-93ec52da40d4');
Expand Down

0 comments on commit 43f83ec

Please sign in to comment.