feat: switch to table

This commit is contained in:
Xyphyn committed 2023-08-22 18:22:47 -07:00
1 parent 281ef04c43
commit 114856a052
6 files changed
+72 -26

No files matched your search

+6
View File
@@ -0,0 +1,6 @@
import { getInstance } from '$lib/lemmy.js'
import { redirect } from '@sveltejs/kit'
export function load({ params }) {
throw redirect(300, `/comment/${getInstance()}/${params.instance}`)
}
@@ -0,0 +1,16 @@
import { profile } from '$lib/auth.js'
import { getClient } from '$lib/lemmy.js'
import { redirect } from '@sveltejs/kit'
import { get } from 'svelte/store'
export async function load({ params, fetch }) {
const comment = await getClient(undefined, fetch).getComment({
id: Number(params.id),
auth: get(profile)?.jwt,
})
throw redirect(
300,
`/post/${comment.comment_view.post.id}?thread=${comment.comment_view.comment.path}#${comment.comment_view.comment.id}`
)
}