breautek commented on code in PR #814:
URL:
https://github.com/apache/cordova-plugin-camera/pull/814#discussion_r1230958672
##########
src/android/CameraLauncher.java:
##########
@@ -223,6 +223,37 @@ else if ((this.srcType == PHOTOLIBRARY) || (this.srcType
== SAVEDPHOTOALBUM)) {
// LOCAL METHODS
//--------------------------------------------------------------------------
+ private String[] getPermissions(boolean storageOnly, int mediaType) {
+ if (android.os.Build.VERSION.SDK_INT >= Build.VERSION_CODES.TIRAMISU) {
+ if (storageOnly) {
+ switch (mediaType) {
+ case PICTURE:
+ return new String[]{
Manifest.permission.READ_MEDIA_IMAGES };
Review Comment:
We'll need to test this.
the `CAMERA` permission is not something normally required, but if the
android manifest declares the permisison, then the app must have it granted
(even if we the app doesn't use any camera APIs itself). So requesting the
`CAMERA` permission before was required. I'm not sure that bug is still present
in the Android SDK in API 33.
--
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]