mauron85 / cordova-plugin-background-geolocation

Background and foreground geolocation plugin for Cordova.
Apache License 2.0
538 stars 407 forks source link

Notifications not forwarding to Capacitor PushNotifications in iOS #723

Open Akmalismail opened 4 years ago

Akmalismail commented 4 years ago

Your Environment

Context

First posted here. Currently I am using Ionic 4 + Capacitor + Some Cordova plugins. My app requires the use of background geolocation hence used this cordova plugin. My app also requires firebase push notifications and opted for Capacitor's PushNotification plugin to listen to push notifications. Both of these work fine in Android, however it does not work in iOS.

After some troubleshooting, the notification does indeed get sent to the phone and is received by the app, however this plugins center does not forward the notification received to capacitor's notification center.

Expected Behavior

Plugin should forward notification received to capacitor plugin.

Actual Behavior

Notification gets received by background geolocation plugin, but does not forward to capacitor plugin.

Possible Fix

Steps to Reproduce

  1. Create Ionic Project with capacitor
  2. Install background geolocation plugin as stated here
  3. Add listener for pushNotificationReceived
  4. Run in device and fire an example notification.

Context

Due to this, my app is unable to move forward without sacrificing either core feature.

Debug logs

StevieWag commented 4 years ago

any news on that?

StevieWag commented 4 years ago

found this workaround so far: https://github.com/mauron85/cordova-plugin-background-geolocation/issues/627#issuecomment-576582283

Akmalismail commented 4 years ago

found this workaround so far: #627 (comment)

Im a little occupied at the moment with other stuff but will check this out and see if it works. Thank you