I've registered and enabled push notifications in my code, but on parse.com my device token is "undefined", so are badge and channels. Any suggestions as to why. Thanks.
If you are working on emulator like Genymotion you can try this code for register parse.com
Parse.initialize(this, "YOUR API KEY", "YOUR APP KEY");
PushService.subscribe(this, "CHANNELNAME", YOURCLASSNAME.class);
PushService.setDefaultPushCallback(this, YOURCLASSNAME.class);
ParseInstallation.getCurrentInstallation().saveInBackground();
ParseAnalytics.trackAppOpened(getIntent());
I hope it will work.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.