【发布时间】:2020-04-19 22:58:22
【问题描述】:
error thread photo of storyboard and the problem
我正在尝试检查某个人在某个日期是否存在单击日历(每个人在日历中都有一个与之关联的日期),以及他是否没有转至其他控制器。如果他这样做,我会在其他地方继续。当这个人不存在时,就会出现这个问题。我在下面附上了我的代码,问题是 else 语句中的 performSegue。
我对此很陌生,所以请尽可能简单地解释一下!提前欣赏。
func calendar(_ calendar: FSCalendar, didSelect date: Date, at monthPosition: FSCalendarMonthPosition) {
self.delegate?.dateSelected(dateStart: date)
let person = containsHost(date: date)
if (person != nil) {
performSegue(withIdentifier: "planReceipt", sender: person)
} else { //check sender and logic
performSegue(withIdentifier: "modal", sender: nil) //DOESN'T WORK
}
}
【问题讨论】:
-
调试代码:设置异常断点
-
这是否等同于我显示的错误线程?难道是因为我没有导航控制器?