diff --git a/packages/components/table/src/store/current.ts b/packages/components/table/src/store/current.ts index 6a8589e730..612019504a 100644 --- a/packages/components/table/src/store/current.ts +++ b/packages/components/table/src/store/current.ts @@ -22,11 +22,11 @@ function useCurrent(watcherData: WatcherPropsData) { } const setCurrentRowByKey = (key: string) => { - const { data = [], rowKey } = watcherData + const { data, rowKey } = watcherData let _currentRow = null if (rowKey.value) { _currentRow = arrayFind( - unref(data), + unref(data) || [], item => getRowIdentity(item, rowKey.value) === key, ) }