braze-inc / braze-cordova-sdk

Public repo for the Braze Cordova SDK
https://www.braze.com
Other
21 stars 62 forks source link

No push subscription state update via the app settings #53

Closed jamesyoon11 closed 4 years ago

jamesyoon11 commented 4 years ago

For iOS, the initial push subscription state is 'Subscribed'. And, when the push permission prompt is displayed, I clicked 'Allow' so the push subscription state is moved to 'Opted-In'. This is what I expected so it's good.

Screen Shot 2020-05-04 at 5 00 11 PM

However, I disabled the notification permission via the app settings but the push subscription state is still 'Opted-In' even if I tried to close and reopen the app multiple times.

Screen Shot 2020-05-04 at 5 02 40 PM

How dose it update to 'UnSubscribed' when the permission authorization is denied via the app settings?

radixdev commented 4 years ago

This is expected behavior. After you opt-in at a user level, the only way to mark that user as unsubscribed, or otherwise change from Opted In, is through our user subscription methods.

jamesyoon11 commented 4 years ago

@radixdev thank you for the answer. I thought it was automatically done and we didn't need to implement it on our own. Okay.. So, is the following assumption correct when implementing subscription methods?

Bucimis commented 4 years ago

@jamesyoon11 that looks like a good mapping to me.

jamesyoon11 commented 4 years ago

Thank you for the prompt reply @Bucimis. Closing the issue.