mirror of
https://github.com/whoswhip/Sharpbin.git
synced 2026-12-06 02:48:43 +00:00
12 lines
302 B
TypeScript
12 lines
302 B
TypeScript
import type { LayoutServerLoad } from './$types';
|
|
|
|
export const load: LayoutServerLoad = async ({ fetch, url }) => {
|
|
try {
|
|
const res = await fetch('/api/auth/info');
|
|
const options = await res.json();
|
|
return { options, url: url.href };
|
|
} catch {
|
|
return { options: null, url: url.href };
|
|
}
|
|
};
|