sparrowcode / PermissionsKit

Universal API for request permission and get its statuses.
https://x.com/sparrowcode_ios
MIT License
5.64k stars 462 forks source link

Permission Health can't be present with custom interface #281

Closed yuchenz27 closed 2 years ago

yuchenz27 commented 2 years ago

I want to ask permission for Health. Here is my code

let controller = SPPermissions.list([.camera, .microphone, .health])
controller.present(on: self)

As a result, the health option was not presented in the pop-up list and I got this message in console:

SPPermissions: Permission Health can't be present with custom interface. Use `SPPermissions.Permission.NAME.request()` with requerid parametrs. Permission Health will be filtered.

Could someone tell me how to properly ask Health permission? Thank you very much.

ivanvorobei commented 2 years ago

Hey. Health permission has a lot of type. Better to use native way.