From 942afdaf0b31d245a120c7b72ea4a4b3338abad1 Mon Sep 17 00:00:00 2001 From: Dessalines Date: Tue, 5 Mar 2024 05:14:59 -0500 Subject: [PATCH] Fixing donation package. (#302) --- update_donations.mjs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/update_donations.mjs b/update_donations.mjs index e6c126c..1a4721a 100644 --- a/update_donations.mjs +++ b/update_donations.mjs @@ -4,14 +4,14 @@ import fetch from "node-fetch"; const donationStatsFile = "src/shared/donation_stats.ts"; const USDtoEURUrl = - "https://cdn.jsdelivr.net/gh/fawazahmed0/currency-api@1/latest/currencies/usd/eur.json"; + "https://cdn.jsdelivr.net/npm/@fawazahmed0/currency-api@latest/v1/currencies/usd.json"; const liberaPayUrl = "https://liberapay.com/Lemmy/public.json"; const openCollectiveUrl = "https://opencollective.com/lemmy.json"; const patreonUrl = "https://www.patreon.com/api/campaigns/2692831"; const usdToEurRes = await fetch(USDtoEURUrl); -const usdToEur = (await usdToEurRes.json()).eur; +const usdToEur = (await usdToEurRes.json()).usd.eur; // In weekly USD const liberaPayRes = await fetch(liberaPayUrl);