Skip to content
This repository has been archived by the owner on Jan 5, 2024. It is now read-only.

Commit

Permalink
Revert "[iOS] Update permissions flow for iOS 11 UIImagePickerControl…
Browse files Browse the repository at this point in the history
…ler (react-native-image-picker#819)"

This reverts commit ab4d858.
  • Loading branch information
janicduplessis committed Jan 6, 2019
1 parent a5d2938 commit 6735364
Showing 1 changed file with 7 additions and 12 deletions.
19 changes: 7 additions & 12 deletions ios/ImagePickerManager.m
Original file line number Diff line number Diff line change
Expand Up @@ -204,19 +204,14 @@ - (void)launchImagePicker:(RNImagePickerTarget)target
}];
}
else { // RNImagePickerTargetLibrarySingleImage
if (@available(iOS 11.0, *)) {
// iOS 11 no longer requires permission to access single image
showPickerViewController();
} else {
[self checkPhotosPermissions:^(BOOL granted) {
if (!granted) {
self.callback(@[@{@"error": @"Photo library permissions not granted"}]);
return;
}
[self checkPhotosPermissions:^(BOOL granted) {
if (!granted) {
self.callback(@[@{@"error": @"Photo library permissions not granted"}]);
return;
}

showPickerViewController();
}];
};
showPickerViewController();
}];
}
}

Expand Down

0 comments on commit 6735364

Please sign in to comment.