[@capacitor/local-notifications] - iOS and Android - No notification received when the setting manually changed.
Bug Report
Plugin(s)
"@capacitor/app": "^6.0.0", "@capacitor/local-notifications": "^6.0.0",
Capacitor Version
6
Platform(s)
iOS And Android
Current Behaviour
- open your application for the first time.
- DO NOT allow receiving notification.
- Switch to app setting
- MANUALLY allow notification to be sent.
- go back to your app. And run:
await LocalNotifications.schedule({
notifications: [
{
id: Math.floor((Math.random() * 1000000) + 1),
title: 'Title',
body: 'Body',
schedule: {
at: t, // any Date
allowWhileIdle: true,
},
}
]
});
Expected Behaviour
To the local notification to be send at t time.
What happen
No notification is send.
Note
This working fine if I allow the notification on first opening the app.
This issue needs more information before it can be addressed. In particular, the reporter needs to provide a minimal sample app that demonstrates the issue. If no sample app is provided within 15 days, the issue will be closed.
Please see the Contributing Guide for how to create a Sample App.
Thanks! Ionitron 💙
Hi Ionitron
It's way to easy to reproduce
Create an empty project run: npm i @capacitor/local-notifications on the onload page add the code from the bug report.
test following the step shown on the bug report.
That simple.