Ionic BLE plugin work weird on IOS


#1

It’s IOS.
after searching , I try to connect .
with below code.

it works very well with hardcoded id like var bb
but with variable a, it doesn’t work even though it has same value.
I checked log and value is same but the difference is that bb which is fine to connect is without “”
but var a which can’t connect is with "

what is the reason for a is not connectable to bluetooth ?

//a is 03A23620-E31F-FA2C-5E8C-F1C3C35A0A50

var bb=“03A23620-E31F-FA2C-5E8C-F1C3C35A0A50”;
console.log(“this is bb”+bb);
console.log(typeof(bb));
console.log(“this is a:”);
console.log(a);
console.log(typeof(a));
this.ble.connect(a).subscribe(rr=>{

Log says
ionicBLEAttendance[712:152973] this is bb 03A23620-E31F-FA2C-5E8C-F1C3C35A0A50
2018-06-26 20:28:14.771653+0900 ionicBLEAttendance[712:152973] string
2018-06-26 20:28:14.771828+0900 ionicBLEAttendance[712:152973] this is a:
2018-06-26 20:28:14.772004+0900 ionicBLEAttendance[712:152973] “03A23620-E31F-FA2C-5E8C-F1C3C35A0A50”
2018-06-26 20:28:14.772449+0900 ionicBLEAttendance[712:152973] string