mirror of
https://github.com/langgenius/dify.git
synced 2026-09-03 06:53:26 +08:00
12 lines
378 B
TypeScript
12 lines
378 B
TypeScript
import type { ReactNode } from 'react'
|
|
import { ensureSystemFeatures } from '@/features/system-features/server'
|
|
import { redirect } from '@/next/navigation'
|
|
|
|
export default async function Layout({ children }: { children: ReactNode }) {
|
|
const systemFeatures = await ensureSystemFeatures()
|
|
|
|
if (!systemFeatures.knowledge_fs_enabled) redirect('/datasets')
|
|
|
|
return children
|
|
}
|