immich/web/src/routes/admin/user-management/+page.ts
martin 7a1f25b515
feat(web): add warning when setting a quota superior to the disk size (#6737)
* refactor: inline warning

* fix: do not use onmount

* chore: remove outdated comment

* wording

---------

Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
2024-01-30 17:21:45 +00:00

16 lines
424 B
TypeScript

import { authenticate, requestServerInfo } from '$lib/utils/auth';
import { api } from '@api';
import type { PageLoad } from './$types';
export const load = (async () => {
await authenticate({ admin: true });
await requestServerInfo();
const { data: allUsers } = await api.userApi.getAllUsers({ isAll: false });
return {
allUsers,
meta: {
title: 'User Management',
},
};
}) satisfies PageLoad;