Quantcast
Channel: Ionic Forum - Latest topics
Viewing all articles
Browse latest Browse all 70434

Doesn't asks for permissions on initial load

$
0
0

@divyasmehta wrote:

I have an ionic project. I am deploying this app into android. I want to access device’s microphone for which I have added permission in AndroidManifest.xml:

I have also added following code:

this.androidPermissions.checkPermission(this.androidPermissions.PERMISSION.RECORD_AUDIO).then(

        result => console.log('Has record audio permission?', result.hasPermission),

        err => {

          this.androidPermissions.requestPermission(this.androidPermissions.PERMISSION.RECORD_AUDIO).then((data: any) => {

            if (data.hasPermission) {

              console.log("have record audio permission");

            }

          });

        }

      );

yet it is not asking user for permissions on initial load. I am using Cordova. It is not going in the error section while checking for permissions.
Can anyone help me with this?

Posts: 1

Participants: 1

Read full topic


Viewing all articles
Browse latest Browse all 70434

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>