diff --git a/android/capacitor/src/main/java/com/getcapacitor/Bridge.java b/android/capacitor/src/main/java/com/getcapacitor/Bridge.java index f926386104..cd582024dd 100644 --- a/android/capacitor/src/main/java/com/getcapacitor/Bridge.java +++ b/android/capacitor/src/main/java/com/getcapacitor/Bridge.java @@ -789,7 +789,7 @@ public void onRequestPermissionsResult(int requestCode, String[] permissions, in if (validatePermissions(plugin.getInstance(), savedPermissionCall, permissions, grantResults)) { // handle request permissions call if (savedPermissionCall.getMethodName().equals("requestPermissions")) { - savedPermissionCall.resolve(getPermissionStates(plugin.getInstance())); + savedPermissionCall.resolve(plugin.getInstance().getPermissionStates()); } else { // handle permission requests by other methods on the plugin plugin.getInstance().onRequestPermissionsResult(savedPermissionCall, requestCode, permissions, grantResults); diff --git a/android/capacitor/src/main/java/com/getcapacitor/Plugin.java b/android/capacitor/src/main/java/com/getcapacitor/Plugin.java index 899c3b60da..b569986626 100644 --- a/android/capacitor/src/main/java/com/getcapacitor/Plugin.java +++ b/android/capacitor/src/main/java/com/getcapacitor/Plugin.java @@ -494,7 +494,7 @@ public void removeAllListeners(PluginCall call) { */ @PluginMethod public void checkPermissions(PluginCall pluginCall) { - JSObject permissionsResult = bridge.getPermissionStates(this); + JSObject permissionsResult = getPermissionStates(); if (permissionsResult.length() == 0) { // if no permissions are defined on the plugin, resolve undefined