|
|
|
@ -805,7 +805,9 @@ class PairingController extends GetxController with WidgetsBindingObserver { |
|
|
|
final existingDevice = User.instance.devices.firstWhere( |
|
|
|
(d) => |
|
|
|
d.devicetype == 1 && |
|
|
|
d.devicename.contains(deviceName) && |
|
|
|
// 蓝牙名称校验已移除:MAC 在本机绑定列表中已经全局唯一, |
|
|
|
// 叠加 name.contains 反而会在用户重命名设备或广播未带 LocalName 时误判已绑定设备为新设备。 |
|
|
|
// d.devicename.contains(deviceName) && |
|
|
|
d.devicemac == device.address, |
|
|
|
orElse: () => UserDevice( |
|
|
|
id: -1, |
|
|
|
@ -836,7 +838,9 @@ class PairingController extends GetxController with WidgetsBindingObserver { |
|
|
|
final existingDevice = User.instance.devices.firstWhere( |
|
|
|
(d) => |
|
|
|
d.devicetype != 1 && |
|
|
|
d.devicename.contains(deviceName) && |
|
|
|
// 蓝牙名称校验已移除:MAC 在本机绑定列表中已经全局唯一, |
|
|
|
// 叠加 name.contains 反而会在用户重命名设备或广播未带 LocalName 时误判已绑定设备为新设备。 |
|
|
|
// d.devicename.contains(deviceName) && |
|
|
|
d.devicemac == device.address, |
|
|
|
orElse: () => UserDevice( |
|
|
|
id: -1, |
|
|
|
|