invertase / notifee

⚛️ A feature rich notifications library for React Native.
https://notifee.app
Apache License 2.0
1.88k stars 228 forks source link

Android notificationSettings not up-to-date #954

Closed JaRoMasterDev closed 9 months ago

JaRoMasterDev commented 10 months ago

I have been following the documentation to add trigger notifications. In order to ask for the correct permissions, I have included this code from the documentation:

const settings = await notifee.getNotificationSettings();
if (settings.android.alarm == AndroidNotificationSetting.ENABLED) {
  //Create timestamp trigger
} else {
  // Show some user information to educate them on what exact alarm permission is,
  // and why it is necessary for your app functionality, then send them to system preferences:
  await notifee.openAlarmPermissionSettings();
}

I have encountered the following problem: When I disable the notification permission from the settings, settings.android.alarm is still 1, which means that it is allowed. Due to this, the user doesn't get asked to grant this permission. Does anyone know what's causing this problem?

github-actions[bot] commented 9 months ago

Hello 👋, to help manage issues we automatically close stale issues.

This issue has been automatically marked as stale because it has not had activity for quite some time.Has this issue been fixed, or does it still require attention?

This issue will be closed in 15 days if no further activity occurs.

Thank you for your contributions.