gpt4 book ai didi

ios - 更新 Xcode Swift

转载 作者:行者123 更新时间:2023-11-28 10:35:34 25 4
gpt4 key购买 nike

我只是在更新后更新 xcode(10.0) 我更新了 swift 语言版本 (4.2) 但是在更新过程中 swift 语言给我一些错误我真的很困惑如何解决这个问题:

错误:

Cannot subscript a value of type '[String : Any]' with an index of type 'UIImagePickerController.InfoKey'

@objc(imagePickerController:didFinishPickingMediaWithInfo:) func  imagePickerController(_ picker: UIImagePickerController, didFinishPickingMediaWithInfo Info: [String: Any]){
let mediatype = Info[UIImagePickerControllerMediaType] as! NSString
if mediatype.isEqual(to: kUTTypeImage as String) {
let imagecopy = Info[UIImagePickerControllerOriginalImage] as! UIImage
profileImage.image = imagecopy
if newpic == true {
UIImageWriteToSavedPhotosAlbum(imagecopy, self, #selector(imageError),nil)
}
}
self.dismiss(animated:true,completion:nil)
onlyUploadImage()
}

错误屏幕截图

Screen Shot

有人可以向我解释如何解决这个问题吗,我已经尝试解决这个问题但还没有结果。

谢谢

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com