activate live statistics via settings
All checks were successful
deploy / build-and-deploy (push) Successful in 16s

This commit is contained in:
2025-11-11 02:06:38 +01:00
parent 607163e503
commit 87d3f7c3af
4 changed files with 22 additions and 4 deletions

View File

@@ -4,12 +4,13 @@ import Countdown from '@app/website/index/Countdown.svelte';
import LiveStats from '@app/website/index/LiveStats.svelte';
import Craftattack from '@assets/img/craftattack.webp';
import Background from '@assets/img/background.webp';
import { START_DATE, STATISTICS_ENDPOINT } from 'astro:env/server';
import { START_DATE } from 'astro:env/server';
import { getSetting, SettingKey } from '@util/settings';
import { db } from '@db/database.ts';
const signupEnabled = await getSetting(db, SettingKey.SignupEnabled, false);
const signupInfoMessage = await getSetting(db, SettingKey.SignupInfoMessage);
const statisticsEnabled = await getSetting(db, SettingKey.LiveStatisticsEnabled, false);
const information = [
{
@@ -98,7 +99,7 @@ const information = [
<div class="flex flex-col justify-center items-center py-20 bg-base-100">
{
STATISTICS_ENDPOINT && (
statisticsEnabled && (
<>
<LiveStats />
<div class="divider divider-horizontal mx-auto my-6 h-18" />