feature():设备为空或设备名为空的情况不崩溃

This commit is contained in:
lvwang2002 2024-12-18 08:52:26 +08:00
parent da6bdba5a0
commit 736445cc39
1 changed files with 1 additions and 1 deletions

View File

@ -731,7 +731,7 @@ export default class RNDYGlucoseDriver {
return; return;
} }
const deviceList = deviceInfos.filter((device) => { const deviceList = deviceInfos.filter((device) => {
return device.deviceName.indexOf('TH-') >= 0 return device?.deviceName?.indexOf('TH-') >= 0
}); });
this._onUpdateDeviceList(deviceList); this._onUpdateDeviceList(deviceList);