Finalize dev-1.3 upgrades and Seerr updates
This commit is contained in:
@@ -2,6 +2,7 @@ import { notFound } from 'next/navigation'
|
||||
import SettingsPage from '../SettingsPage'
|
||||
|
||||
const ALLOWED_SECTIONS = new Set([
|
||||
'seerr',
|
||||
'jellyseerr',
|
||||
'jellyfin',
|
||||
'artwork',
|
||||
@@ -20,12 +21,13 @@ const ALLOWED_SECTIONS = new Set([
|
||||
])
|
||||
|
||||
type PageProps = {
|
||||
params: { section: string }
|
||||
params: Promise<{ section: string }>
|
||||
}
|
||||
|
||||
export default function AdminSectionPage({ params }: PageProps) {
|
||||
if (!ALLOWED_SECTIONS.has(params.section)) {
|
||||
export default async function AdminSectionPage({ params }: PageProps) {
|
||||
const { section } = await params
|
||||
if (!ALLOWED_SECTIONS.has(section)) {
|
||||
notFound()
|
||||
}
|
||||
return <SettingsPage section={params.section} />
|
||||
return <SettingsPage section={section} />
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user