I found a bug in all of my apps concerning the @ionic-native/camera respectively the cordova-plugin-camera plugin. I also downloaded some prominent ionic built apps from the Appstore and they all seem to have the same bug.
Unfortunately, the dialog for the Photolibrary Usage Permission is not firing using the above mentioned plugins. The apps behave as follows:
If one is using the sourceType PictureSourceType.CAMERA than the dialog for the permissions with the “Privacy - Camera Usage Description” will be displayed as expected.
If one is using the sourceType PictureSourceType.PHOTOLIBRARY than no dialog will be displayed and the access to the photolibrary will be granted immediately.
In my info.plist file is 100% an entry for the “Privacy - Photo Library Usage Description” (see screenshot) and there are no build errors (also internal/external Testflights work perfectly fine).
I also detected in the iOS Settings for the Apps, that the entry for the Photolibrary permission is missing (see screenshots).
In my opinion that might be a bug for future rejections from the Appstore.
I’m using the Versions
@ionic-native/camera: 4.11.0 and
<plugin name="cordova-plugin-camera" spec="^4.0.3">
App built with Ionic
Ionic: ionic (Ionic CLI) : 4.0.6 (/Users/mike/.nvm/versions/node/v10.7.0/lib/node_modules/ionic) Ionic Framework : ionic-angular 3.9.2 @ionic/app-scripts : 3.1.11 Cordova: cordova (Cordova CLI) : 8.0.0 Cordova Platforms : android 7.0.0, ios 4.5.5 System: Android SDK Tools : 26.1.1 ios-deploy : 2.0.0 NodeJS : v10.7.0 (/Users/mike/.nvm/versions/node/v10.7.0/bin/node) npm : 6.2.0 OS : macOS High Sierra Xcode : Xcode 9.4.1 Build version 9F2000 Environment: ANDROID_HOME : /Users/mike/Library/Android/sdk