12 lines
292 B
TypeScript
12 lines
292 B
TypeScript
![]() |
import { error, type Load, type ServerLoad } from "@sveltejs/kit"
|
||
|
import type { PageLoad } from "./$types"
|
||
|
|
||
|
export const load: PageLoad = async ({ params }) => {
|
||
|
if (params.id) {
|
||
|
return {
|
||
|
roomId: params.id,
|
||
|
}
|
||
|
}
|
||
|
error(400, "Please provide a room id")
|
||
|
}
|