diff --git a/src/routes/pubnix/+page.server.ts b/src/routes/pubnix/+page.server.ts index 1c33249..f48f33c 100644 --- a/src/routes/pubnix/+page.server.ts +++ b/src/routes/pubnix/+page.server.ts @@ -9,7 +9,6 @@ export const load = (async () => { return { users: get(pubnixUsers), - onlineUserCount: get(pubnixUsers).length, ...meta } }) satisfies PageServerLoad; diff --git a/src/routes/pubnix/+page.svelte b/src/routes/pubnix/+page.svelte index 516dc41..b2668bc 100644 --- a/src/routes/pubnix/+page.svelte +++ b/src/routes/pubnix/+page.svelte @@ -37,7 +37,7 @@ {#if !data.users.error} {#if data.users.users.some(isOnline)} -

There are {onlineUserCount} users online out of {userCount} users.

+

There are {onlineUserCount} users online out of {userCount} users.

{#each data.users.users as user} {#if user.online} diff --git a/src/routes/pubnix/users/+page.svelte b/src/routes/pubnix/users/+page.svelte index 87e75db..47fc32f 100644 --- a/src/routes/pubnix/users/+page.svelte +++ b/src/routes/pubnix/users/+page.svelte @@ -3,15 +3,13 @@ export let data: PageData; import User from "../User.svelte"; - - const userCount = data.users.users.length;

{data.title}

{#if !data.users.error} {#if data.users.users.length > 0} -

There are {userCount} users on the pubnix.

+

There are {data.users.users.length} users on the pubnix.

{#each data.users.users as user}