fix(client): cannot read properties of undefined (reading 'split')

This commit is contained in:
chenos 2022-06-29 22:39:55 +08:00
parent 008a7f7f33
commit 947215f96d

View File

@ -35,6 +35,9 @@ export const useCollectionManager = () => {
},
getCollectionField,
getCollectionJoinField(name: string) {
if (!name) {
return;
}
const [collectionName, ...fieldNames] = name.split('.');
if (!fieldNames?.length) {
return;