Table: fix Destructuring assignment bug (#2893)

This commit is contained in:
wanghaitao 2021-08-28 03:48:03 +08:00 committed by GitHub
parent fdbbd15187
commit c1445d80de
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -22,11 +22,11 @@ function useCurrent<T>(watcherData: WatcherPropsData<T>) {
}
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,
)
}