fix(about): allow donations to be sent from self-hosted instances

This commit is contained in:
azurejelly 2025-10-28 12:20:57 -04:00 committed by Maya
parent 03f27d9b7b
commit 36be6c6e52
1 changed files with 4 additions and 5 deletions

View File

@ -8,9 +8,8 @@
import avatarJovannMC from "$lib/assets/avatars/jovannmc.jpg"; import avatarJovannMC from "$lib/assets/avatars/jovannmc.jpg";
import avatarRealmy from "$lib/assets/avatars/realmy.jpg"; import avatarRealmy from "$lib/assets/avatars/realmy.jpg";
import avatarAzurejelly from "$lib/assets/avatars/azurejelly.jpg"; import avatarAzurejelly from "$lib/assets/avatars/azurejelly.jpg";
import { PUB_DONATION_URL, PUB_STRIPE_KEY } from "$env/static/public";
import { DISABLE_ALL_EXTERNAL_REQUESTS, GITHUB_API_URL } from "$lib/consts"; import { DISABLE_ALL_EXTERNAL_REQUESTS, GITHUB_API_URL } from "$lib/consts";
import { dev } from "$app/environment";
import { page } from "$app/state";
import { m } from "$lib/paraglide/messages"; import { m } from "$lib/paraglide/messages";
import { ToastManager } from "$lib/toast/index.svelte"; import { ToastManager } from "$lib/toast/index.svelte";
// import { dev } from "$app/environment"; // import { dev } from "$app/environment";
@ -138,9 +137,9 @@
} }
}); });
const donationsEnabled = const donationsEnabled = PUB_STRIPE_KEY
(dev || page.url.origin.endsWith("//vert.sh")) && && PUB_DONATION_URL
!DISABLE_ALL_EXTERNAL_REQUESTS; && !DISABLE_ALL_EXTERNAL_REQUESTS;
</script> </script>
<div class="flex flex-col h-full items-center"> <div class="flex flex-col h-full items-center">