Hello,
I have the following issue:
In Android 7.0, when getting
Push.getPushKey() (not in registeredForPush() method) the first time, it's null.
I have
callSerially(() -> registerPush());
in my start() method and
besides that, I added
if (!Preferences.get("setIt", false)) {
Display.getInstance().registerPush();
Preferences.set("setIt", true);
}
into my pushRegistrationError(String error, int errorCode).
If I kill the app, then open and call Push.getPushKey() the second time, it gives me a valid id.
I put a log to test what is inside of the registeredForPush(String deviceId) method, and it seems to work correctly - the devicePush is not null and shows the id.(devicePush = Push.getPushKey();)
This happens only in Android 7, Android 10 and Android 8 devices register push successfully from the first call.
Thank you.