Skip to content

Commit 3e3699b

Browse files
fix: missing sid on bibCheck call (#258)
1 parent 2c8f73c commit 3e3699b

1 file changed

Lines changed: 9 additions & 6 deletions

File tree

packages/react-tei/src/RetractedBadge/RetractedBadge.tsx

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -60,13 +60,16 @@ type BibCheckIsRetractedResponse = {
6060
}[];
6161

6262
async function getRetractedState(doi: string) {
63-
const response = await fetch(
64-
"https://biblio-ref.services.istex.fr/v1/is-retracted",
65-
{
66-
method: "POST",
67-
body: JSON.stringify([{ value: doi }]),
68-
},
63+
const url = new URL(
64+
"/v1/is-retracted",
65+
"https://biblio-ref.services.istex.fr",
6966
);
67+
url.searchParams.set("sid", "istex-view");
68+
69+
const response = await fetch(url, {
70+
method: "POST",
71+
body: JSON.stringify([{ value: doi }]),
72+
});
7073
if (!response.ok) {
7174
console.error(response);
7275
throw new Error("Error from bibCheck web service");

0 commit comments

Comments
 (0)