aboutsummaryrefslogtreecommitdiffstats
path: root/src/routes/(app)/contacts/+server.ts
blob: e448bda29704cdc1940af61144711f7893863be3 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
import { auth, get } from "$lib/utils";
import { json } from "@sveltejs/kit";

export async function GET({ cookies }) {
	try {
		const contacts = await get("/contacts", auth(cookies));
		return json(contacts);
	} catch (e) {
		console.log(e);
		return json({});
	}
}