This is an automated email from the ASF dual-hosted git repository.

GitToTheHub pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/cordova-android.git


The following commit(s) were added to refs/heads/master by this push:
     new 9c3d8268 Remove unused private Method 
`PermissionHelper.deliverPermissionResult` (#1858)
9c3d8268 is described below

commit 9c3d82680e36035ba5e21dcc7aa40caaee8b7351
Author: Manuel Beck <[email protected]>
AuthorDate: Mon Apr 20 18:03:30 2026 +0200

    Remove unused private Method `PermissionHelper.deliverPermissionResult` 
(#1858)
    
    - The method deliverPermissionResult is private and nowhere used. Because 
it's private, it cannot be called from outside and cannot be overwritten and is 
safe to remove.
---
 framework/src/org/apache/cordova/PermissionHelper.java | 16 ----------------
 1 file changed, 16 deletions(-)

diff --git a/framework/src/org/apache/cordova/PermissionHelper.java 
b/framework/src/org/apache/cordova/PermissionHelper.java
index 82f7b1c4..5c6e777c 100644
--- a/framework/src/org/apache/cordova/PermissionHelper.java
+++ b/framework/src/org/apache/cordova/PermissionHelper.java
@@ -29,8 +29,6 @@ import android.content.pm.PackageManager;
  * written for cordova-android 5.0.0+ can still compile with earlier 
cordova-android versions.
  */
 public class PermissionHelper {
-    private static final String LOG_TAG = "CordovaPermissionHelper";
-
     /**
      * Requests a "dangerous" permission for the application at runtime. This 
is a helper method
      * alternative to cordovaInterface.requestPermission() that does not 
require the project to be
@@ -71,18 +69,4 @@ public class PermissionHelper {
     public static boolean hasPermission(CordovaPlugin plugin, String 
permission) {
         return plugin.cordova.hasPermission(permission);
     }
-
-    private static void deliverPermissionResult(CordovaPlugin plugin, int 
requestCode, String[] permissions) {
-        // Generate the request results
-        int[] requestResults = new int[permissions.length];
-        Arrays.fill(requestResults, PackageManager.PERMISSION_GRANTED);
-
-        try {
-            // This one is deprecated - see 
https://github.com/apache/cordova-android/issues/592
-            plugin.onRequestPermissionResult(requestCode, permissions, 
requestResults);
-            plugin.onRequestPermissionsResult(requestCode, permissions, 
requestResults);
-        } catch (JSONException e) {
-            LOG.e(LOG_TAG, "JSONException when delivering permissions 
results", e);
-        }
-    }
 }


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to