Set push notifications enabled when network is available

This commit is contained in:
Mickaël Turnel 2018-10-29 14:22:59 +01:00
parent 0b56c0bac2
commit 1704c53e80

View file

@ -1591,7 +1591,11 @@ public class LinphoneManager implements CoreListener, SensorEventListener, Accou
@Override
public void onNetworkReachable(Core lc, boolean enable) {
if (enable) {
// When network isn't available, push informations might not be set. This should fix the issue.
LinphonePreferences prefs = LinphonePreferences.instance();
prefs.setPushNotificationEnabled(prefs.isPushNotificationEnabled());
}
}
@Override