phonegap/phonegap-plugin-push

Sound turned off by default in Xiaomi Redmi phones

MohitKonaje opened this issue · 0 comments

Expected Behaviour

Should Play sound when notification is received.

Actual Behaviour

No sound played when notification arrives (Only on Xiaomi Redmi MIUI phones)
Works when sound turned on in phone settings
is this default behavior in xiaomi miui based phones?
WhatsApp Image 2020-04-23 at 8 53 59 PM

Reproduce Scenario (including but not limited to)

Steps to Reproduce

Configure plugin as per docs and send notification to a Xiaomi Redmi Phone

Platform and Version (eg. Android 5.0 or iOS 9.2.1)

Android 8.0

(Android) What device vendor (e.g. Samsung, HTC, Sony...)

Xiaomi Redmi Note 4 and 5 - MIUI 11 Global ROM

Cordova CLI version and cordova platform version

cordova --version                                    # e.g. 8.1.1 (cordova-lib@8.1.0)
cordova platform version android                     # e.g. 8.1.0

Plugin version

cordova plugin version | grep phonegap-plugin-push   # e.g. 2.3.0

Sample Push Data Payload

{
"data": {
"android_channel_id":"appchannel",
"notId": randomNumber
"title":"Message Recieved",
"body": Test message body",
"sound": "default",
"click_action":"FCM_PLUGIN_ACTIVITY",
"image" : VALID_URL,
"image-type": "circle",
"key": "value",
},
"token":VALID_FCMID
}

Sample Code that illustrates the problem

Logs taken while reproducing problem