Query Response:
An error occurred while executing the query:
- Error: platformexception(permissionhandler.permissionmanager, a request for permissions is already running, please wait for it to finish before doing another request (note that you can request multiple permissions at the same time)., null, null)
Explanation:
This error suggests that a request for permissions is already in progress and another request cannot be made until the ongoing request has finished. The “PermissionHandler” component in your platform is managing these requests.
It’s important to note that the “PermissionHandler” allows simultaneous requests for multiple permissions. However, you should wait for the ongoing request to complete before initiating another one.
Example:
// Simulating a scenario where a permission request is already running
PermissionHandler permissionHandler = new PermissionHandler();
permissionHandler.checkPermissionStatus('camera');
permissionHandler.requestPermissions(['location']);