我正在学习开发,这是我的代码。
`
override func prepare(for segue: UIStoryboardSegue, sender: Any?) {
guard let identifier = segue.identifier,
let mapVC = segue.identifier as? MapViewController
else {return}
mapVC.incomeSegueIndetifire = identifier
if identifier == "showPlace"{
mapVC.place.name = placeName.text!
mapVC.place.location = placeLocation.text!
mapVC.place.type = placeType.text!
mapVC.place.imageData = placeImage.image?.pngData()
}
} `
我按照课程中的方式做了,但我在帖子标题中写了一个简短的错误。如何解决?
如果你这样尝试呢?(不幸的是,现在手头没有 Macbook :( )