03-20-2018 10:24
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

03-20-2018 10:24
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Here's a querk I've found today when using the messaging API.
I have this code in app that makes sure messaging is available with the commpanion before trying to send messages:
if ( messaging.peerSocket.readyState == messaging.peerSocket.OPEN ) { // Do Something clever with the companion }
I've found that, occasionally, even when this returns true and the Ionic tries to send a message to the companion them message will never get sent (I've waited about 3-4 minutes and its still trying to send), until you turn the phones screen on. I didnt have to unlock the phone just turn on the screen and the message is instantly sent and everything moves on as expected.
I've only tested this with my Ionic running 2.0 and my Google Pixel 2XL so I'm not sure if this excists on the previous Ionic OS or with other Android phones, but I thought it was worth mentioning incase anyone else is having problems with messages going from the device to the companion
Answered! Go to the Best Answer.

Accepted Solutions
03-27-2018 17:13
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


03-27-2018 17:13
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Is it possible that the Fitbit app is being suspended for battery reasons on your phone?

03-27-2018 17:13
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


03-27-2018 17:13
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Is it possible that the Fitbit app is being suspended for battery reasons on your phone?

