Tuesday, February 20, 2018

push notification - Android GCM and multiple tokens

I register in GCM with GoogleCloudMessaging.getInstance(context); and save received token on device. Then send it to server and it's associated with user account. If I uninstall my app without logging out and install again and log in with another user, I receive new token and send it to server. And when pushes being send to first user I see them when I logged in with second user.




Why does GCM sends me different tokens and how can I handle this?

No comments:

Post a Comment

plot explanation - Why did Peaches' mom hang on the tree? - Movies & TV

In the middle of the movie Ice Age: Continental Drift Peaches' mom asked Peaches to go to sleep. Then, she hung on the tree. This parti...