Flutter IOS shouldn’t be displaying location permission dialog when utilizing permission_handler package deal


How can I repair my flutter ios software not displaying the permission dialog am at present utilizing permission_handler 10.0.0 package deal the package deal works high-quality in android however on ios the dialog to both grant or deny the permission shouldn’t be pop-up in any respect.
Right here is the operate for the request

chkPermissionLoc(ctx) async {
var perLocation = await Permission.location.standing;
    if (perLocation.isDenied) {
        await [Permission.location].request();//This is not working
        print('Permission is Denied');
    } else if (perLocation.isGranted) {
      print('Permission is Granted');
    } else if (perLocation.isPermanentlyDenied) {
      print('Permission is completely denied');
    } else if (perLocation.isRestricted) {
      print('Permission is OS restricted');
    } else if (perLocation.isLimited) {
      print('Permission is Restricted');

The applying merely printed Permission is Denied however the operate earlier than it which is suppose to point out the dialog shouldn’t be getting known as in any respect.
I’ve added the string values within the data.plist file as per the documentation within the package deal however nonetheless the identical problem.

    <string>Want location when in use</string>
    <string>At all times and when in use!</string>
    <string>Older gadgets want location.</string>
    <string>Can I haz location all the time?</string>

Any assist might be tremendously appreciated


Leave a Reply