While converting from old version of swift I am getting a warning for
func imagePickerController(_ picker: UIImagePickerController, didFinishPickingMediaWithInfo info: [String: AnyObject])
The warning is
Instance method 'imagePickerController(:didFinishPickingMediaWithInfo:)' nearly matches optional requirement 'imagePickerController(:didFinishPickingMediaWithInfo:)' of protocol UIImagePickerControllerDelegae
The problem here is is that as far as my eyes tell, what it complains about and what it says nearly matches are 100% the same. How do I solve this warning?
In newer swift version, method should be
func imagePickerController(_ picker: UIImagePickerController, didFinishPickingMediaWithInfo info: [UIImagePickerController.InfoKey : Any])
then, warning doesn't show up.
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