Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is possible to make it work without fine location activated? (Only iOS) #35

Open
mrigo opened this issue Jul 1, 2019 · 3 comments
Open

Comments

@mrigo
Copy link

mrigo commented Jul 1, 2019

Hello,
I'm interested in this library, but I don't need an "always" permission when using my app, but only when in use.
Is it possible to do?
When the app has only "when in use" permission, I get the error:
"Access fine location is not permitted".

Is related to the permission level?

Thanks

@mrigo mrigo changed the title Is possible to make it work without fine location activated? Is possible to make it work without fine location activated? (Only iOS) Jul 1, 2019
@mrigo
Copy link
Author

mrigo commented Jul 1, 2019

I've added the Only iOS option because I think in Android there's no such problem, right?

@mikaelengstrom
Copy link
Contributor

As of now that is not possible. The IOS code have hardcoded checks for kCLAuthorizationStatusAuthorizedAlways

However if I were to do something like this when app is in focus only I would probably just start updating for location changes and check weather or not current location is in bounds using pure js (via some great-circle distance lib) since i would probably need greater accuracy, less delay and delivery consistancy than android/ios geofencing services provide. But that would drain more battery, so i guess it depends on the use-case. Would that fit your use-case or do you think this lib should update to resolve that hard-coded permission check?

@mrigo
Copy link
Author

mrigo commented Jul 31, 2019

Thanks for the reply!
In my case, I must start an audio file when the user enters into a region, but this library is not working so well both Android and iOS, not registering the entering in a region.
Also, users can choose "only when in use" permission, making this library useless :(
I'll try monitoring user position, but I'm afraid for the battery like you said...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants