Showing
1 changed file
with
1 additions
and
1 deletions
@@ -102,7 +102,7 @@ | @@ -102,7 +102,7 @@ | ||
102 | // 设备详情 | 102 | // 设备详情 |
103 | const res = await getDeviceDetail(id); | 103 | const res = await getDeviceDetail(id); |
104 | deviceDetail.value = res; | 104 | deviceDetail.value = res; |
105 | - const { latitude, longitude, address } = res.deviceInfo; | 105 | + const { latitude, longitude, address } = res.deviceInfo || {}; |
106 | if (latitude) { | 106 | if (latitude) { |
107 | deviceDetailRef.value.initMap(longitude, latitude, address); | 107 | deviceDetailRef.value.initMap(longitude, latitude, address); |
108 | } | 108 | } |