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

isRequestingPermission() Always returns false for location #487

Open
5 tasks done
patrickbluth-breathesuite opened this issue Dec 9, 2022 · 0 comments
Open
5 tasks done

Comments

@patrickbluth-breathesuite

Bug report

CHECKLIST

  • I have reproduced the issue using the example project or provided the necessary information to reproduce the issue.
  • I have checked that no similar issues (open or closed) already exist.

Current behavior:

  • Running Android
  • Request location permission
  • While the permission dialog is open, call isRequestingPermission()
  • Value will always be false (tested with location and bluetooth)

Expected behavior:
While the location permission dialog is open, isRequestingPermission() should return true

Steps to reproduce:

  • Clone the example project
  • Add logging for the function call in change listeners
if(platform === "android" || platform === "ios") {
        setInterval(() => {
            console.log(cordova.plugins.diagnostic.isRequestingPermission());
        }, 1000)
//... 
  • Scroll down and click 'Request Camera Authorization'
  • While the dialog is open, true is logged
  • Click 'Request Location Authorization'
  • While the dialog is open false is still logged

Screenshots

Environment information

  • Cordova CLI version
    • 11.0.0
  • Cordova platform version
    • android 11.0.0
  • Plugins & versions installed in project (including this plugin)
    • cordova-plugin-androidx-adapter 1.1.3 "cordova-plugin-androidx-adapter"
    • cordova-plugin-camera 6.0.0 "Camera"
    • cordova-plugin-device 2.0.3 "Device"
    • cordova-plugin-file 7.0.0 "File"
    • cordova-plugin-geolocation 4.1.0 "Geolocation"
    • cordova-plugin-statusbar 3.0.0 "StatusBar"
    • cordova.plugins.diagnostic 7.1.1 "Diagnostic"
  • Dev machine OS and version, e.g.
    • OSX
      • 12.0.1

Runtime issue

  • Device details
    • Pixel 4
    • Pixel 4a
  • OS details
    • Android 11, Android 13

Android build issue:

  • Node JS version
    • 17.3.0
  • Gradle version
    • 7.4.2
  • Target Android SDK version
    • 32
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

1 participant