if let popupButton = result?.control as? NSPopUpButto {
if popupButton.numberOfItems <= 1 {
// blahblah
}
}
if let popupButton = result?.control as? NSPopUpButton && popupButton.numberOfItems <= 1 {}
unresolved identifier
if
You can do it this way:
if let popupButton = result?.control as? NSPopUpButton, popupButton.numberOfItems <= 1 {
//blahblah
}