ath0mas commented on code in PR #608:
URL: 
https://github.com/apache/cordova-plugin-file/pull/608#discussion_r1435864387


##########
src/android/FileUtils.java:
##########
@@ -543,8 +543,10 @@ private void getReadPermission(String rawArgs, int action, 
CallbackContext callb
     }
 
     private void getWritePermission(String rawArgs, int action, 
CallbackContext callbackContext) {
-        int requestCode = pendingRequests.createRequest(rawArgs, action, 
callbackContext);
-        PermissionHelper.requestPermission(this, requestCode, 
Manifest.permission.WRITE_EXTERNAL_STORAGE);
+        if (android.os.Build.VERSION.SDK_INT < Build.VERSION_CODES.TIRAMISU) {
+            int requestCode = pendingRequests.createRequest(rawArgs, action, 
callbackContext);
+            PermissionHelper.requestPermission(this, requestCode, 
Manifest.permission.WRITE_EXTERNAL_STORAGE);
+        }

Review Comment:
   What is happening here in the `else` case?
   Mostly asking because `getWritePermission` is always called providing a 
`callbackContext`.
   Are we sure it does not wait indefinitely?
   Is doing nothing really fine, or should `callbackContext` be called in every 
case, to guarantee the execution flow continues?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


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

Reply via email to