mirror of
https://github.com/ershisan99/www.git
synced 2025-12-17 21:09:22 +00:00
19 lines
581 B
TypeScript
19 lines
581 B
TypeScript
import { ProfileSettingsPageClient } from '@/app/(home)/profile/settings/page-client'
|
|
import { auth } from '@/server/auth'
|
|
import { HydrateClient, api } from '@/trpc/server'
|
|
import { SessionProvider } from 'next-auth/react'
|
|
import { redirect } from 'next/navigation'
|
|
|
|
export default async function ProfileSettingsPage() {
|
|
const session = await auth()
|
|
if (!session) {
|
|
redirect('/')
|
|
}
|
|
await Promise.all([api.profile.getSocialLinks.prefetch()])
|
|
return (
|
|
<HydrateClient>
|
|
<ProfileSettingsPageClient userId={session.user.discord_id} />
|
|
</HydrateClient>
|
|
)
|
|
}
|