fix: remove redundant props (#4787)

This commit is contained in:
Lesenelir
2024-05-30 18:58:08 +08:00
committed by GitHub
parent a325a294bd
commit 615c009c42
2 changed files with 2 additions and 3 deletions

View File

@@ -7,7 +7,7 @@ export type II18NServerProps = {
children: React.ReactNode children: React.ReactNode
} }
const I18NServer = async ({ const I18NServer = ({
children, children,
}: II18NServerProps) => { }: II18NServerProps) => {
const locale = getLocaleOnServer() const locale = getLocaleOnServer()

View File

@@ -46,8 +46,7 @@ const LocaleLayout = ({
<Topbar/> <Topbar/>
<BrowerInitor> <BrowerInitor>
<SentryInitor> <SentryInitor>
{/* @ts-expect-error Async Server Component */} <I18nServer>{children}</I18nServer>
<I18nServer locale={locale}>{children}</I18nServer>
</SentryInitor> </SentryInitor>
</BrowerInitor> </BrowerInitor>
</body> </body>