优化
This commit is contained in:
@@ -519,12 +519,15 @@
|
||||
const getGroup = async () => {
|
||||
const res = await getApiGroups()
|
||||
if (res.code === 0) {
|
||||
const groups = res.data.groups
|
||||
const groups = Array.isArray(res.data?.groups) ? res.data.groups : []
|
||||
apiGroupOptions.value = groups.map((item) => ({
|
||||
label: item,
|
||||
value: item
|
||||
}))
|
||||
apiGroupMap.value = res.data.apiGroupMap
|
||||
apiGroupMap.value =
|
||||
res.data?.apiGroupMap && typeof res.data.apiGroupMap === 'object'
|
||||
? res.data.apiGroupMap
|
||||
: {}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user