react-native-notifications icon indicating copy to clipboard operation
react-native-notifications copied to clipboard

Code that setting NotificationChannel sound on Android might lead unexpected consequences

Open impodracer opened this issue 1 year ago • 1 comments

I'm using react-native-notifications to create notification channel on android. But some users using Android app complained about notification, something like "I can receive notifications but it doesn't sound". So I struggled to find out why but cannot find out what's going on there.

After some investigations, I found out that setSound() method in lib/android/app/src/main/java/com/wix/reactnativenotifications/core/notification/NotificationChannel.java passes null into soundAttribute parameter. Screenshot 2024-01-13 at 5 16 20 PM

(compared below: same code in notifee/react-native is setting soundAttribute parameter) Screenshot 2024-01-13 at 5 16 01 PM

I'm not good at android so I cannot pick exact cause and consequences, but there might be some differences, and reasons that some user complained about notification sounds.

impodracer avatar Jan 13 '24 08:01 impodracer

I know it's not good reference, but I asked Google Bard about this. -- Sorry, I was desparate :( https://g.co/bard/share/80b658b9e410

impodracer avatar Jan 13 '24 08:01 impodracer

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

stale[bot] avatar Jan 31 '25 23:01 stale[bot]

The issue has been closed for inactivity.

stale[bot] avatar Feb 24 '25 23:02 stale[bot]