ringcentral / engage-digital-messaging-ios

Engage Digital Messaging IOS SDK
Other
10 stars 6 forks source link

[Dimelo sharedInstance].unreadCount can't be obtained when the app starts #43

Closed GD-PeaceMinusone closed 3 years ago

GD-PeaceMinusone commented 3 years ago

As the title says, but I put the app in the background, and when I go back to the foreground, it's immediately can be obtained in this method : applicationWillEnterForeground, Please help me with this question, thank you !

GD-PeaceMinusone commented 3 years ago

One caveat: In the middle of this, no other code is executed, and you can just get the unreadCount when from the background back to the foreground

waelba commented 3 years ago

Hi @GD-PeaceMinusone ,

You can use the same logic as the sampleApp to get the unread count (see updateUnreadCount function).

Regard,