HaylLtd / cordova-background-geolocation-plugin

Background and foreground geolocation plugin for Cordova.
Apache License 2.0
57 stars 66 forks source link

on('authorization') event always return 1 #154

Open karimBenBechir opened 1 year ago

karimBenBechir commented 1 year ago

Describe the bug Hello mates, when trying to handle the toggle location service via the on('authorization') event, i figured out that it's always returning 1 when the toggle is occurring and when the permission changes.

To Reproduce Steps to reproduce the behavior:

  1. BackgroundGeolocation.start()
  2. Toggle location service or remove permission for the app.
  3. See the on('authorization') return

Expected behavior Expecting different status for location status.

Smartphone (please complete the following information):

HarelM commented 1 year ago

Can you better explain the scenario and what is the expected behavior? In any case, I would recommend opening a PR of you know how to solve this. I personally don't use the authorize event so I don't have any knowledge about its behavior...