onMessage is not getting fired
nupurjha opened this issue · comments
Hi,
I am using onMessage method to receive foreground notification but I am not getting notification when mobile app is in foreground.I have written following code in index.js file
cordova.plugins.firebase.messaging.onMessage(function(payload) {
console.log("New foreground FCM message: ", payload);
});
And following lines in AndroidManifest.xml file
The problem is "onMessage" method is not getting fired I am not able to understand why this is happening and even not getting any error. Please let me know if I missed something.
Thanks in advance!