From 199c72a212305d25afca420b47dea32479182b96 Mon Sep 17 00:00:00 2001 From: lijianan <574980606@qq.com> Date: Mon, 16 Jan 2023 16:44:45 +0800 Subject: [PATCH] chore: adjust parameter order (#40252) --- components/form/ErrorList.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/components/form/ErrorList.tsx b/components/form/ErrorList.tsx index a6faf0e3b1..8893e9375b 100644 --- a/components/form/ErrorList.tsx +++ b/components/form/ErrorList.tsx @@ -19,8 +19,8 @@ interface ErrorEntity { function toErrorEntity( error: React.ReactNode, - errorStatus: ValidateStatus | undefined, prefix: string, + errorStatus?: ValidateStatus, index: number = 0, ): ErrorEntity { return { @@ -62,9 +62,9 @@ export default function ErrorList({ const debounceErrors = useDebounce(errors); const debounceWarnings = useDebounce(warnings); - const fullKeyList = React.useMemo(() => { + const fullKeyList = React.useMemo(() => { if (help !== undefined && help !== null) { - return [toErrorEntity(help, helpStatus, 'help')]; + return [toErrorEntity(help, 'help', helpStatus)]; } return [