[chore] Use satisfies syntax for server routes types
This commit is contained in:
@@ -4,10 +4,7 @@ import { fetchAPI } from '$utils/api'
|
||||
import { getRandomItems } from '$utils/functions'
|
||||
|
||||
|
||||
/**
|
||||
* Page Data
|
||||
*/
|
||||
export const load: PageServerLoad = async ({ setHeaders }) => {
|
||||
export const load = (async ({ setHeaders }) => {
|
||||
try {
|
||||
// Get total of published photos
|
||||
const totalRes = await fetchAPI(`query {
|
||||
@@ -56,4 +53,4 @@ export const load: PageServerLoad = async ({ setHeaders }) => {
|
||||
} catch (err) {
|
||||
throw error(500, err.message)
|
||||
}
|
||||
}
|
||||
}) satisfies PageServerLoad
|
||||
|
||||
Reference in New Issue
Block a user