In what cases will I be sad? if I have set allowEditing
as false.
func imagePickerController(_ picker: UIImagePickerController, didFinishPickingMediaWithInfo info: [String : Any]) {
if let selectedImage = info[UIImagePickerControllerOriginalImage] as? UIImage {
// I am happy :)
} else {
// I am sad :(
}
dismiss(animated: true, completion: nil)
}
(I got a crash in iOS 11.2.1 iPhone SE
(as per Crashlytics
), so confused if there are legit conditions where this can fail or it is just an iOS bug.)
changed in IOS 12
image.image = info[UIImagePickerController.InfoKey.originalImage] as? UIImage
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With