File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
iterableapi/src/main/java/com/iterable/iterableapi Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -50,7 +50,7 @@ public class IterableApi {
5050 private String inboxSessionId ;
5151 private IterableAuthManager authManager ;
5252 private HashMap <String , String > deviceAttributes = new HashMap <>();
53- private IterableKeychain keychain ;
53+ public IterableKeychain keychain ;
5454
5555 void fetchRemoteConfiguration () {
5656 apiClient .getRemoteConfiguration (new IterableHelper .IterableActionHandler () {
@@ -395,7 +395,11 @@ private void onForeground() {
395395 boolean isNotificationEnable = sharedPref .getBoolean (IterableConstants .SHARED_PREFS_DEVICE_NOTIFICATIONS_ENABLED , false );
396396 if (sharedInstance .config .autoPushRegistration && sharedInstance .isInitialized () && isNotificationEnable != systemNotificationEnabled ) {
397397 IterableLogger .d (TAG , "Performing automatic push registration" );
398- sharedInstance .registerForPush ();
398+ if (systemNotificationEnabled ) {
399+ sharedInstance .registerForPush ();
400+ } else {
401+ sharedInstance .disablePush ();
402+ }
399403 }
400404 fetchRemoteConfiguration ();
401405
You can’t perform that action at this time.
0 commit comments