Swift - Search using UISearchController and NSPredicate with an array of structs
问题 Currently I'm trying to set up a search bar for my tableView. I want to filter the user's input with NSPredicate to display filtered data from an array of struct objects. But when I try to call .filteredArrayUsingPredicate() on such an array, I get the following error [Course] is not convertible to 'NSArray' . Below is my code and a link to the repo. I'm also open to any better methods of approach. import UIKit import SwiftyJSON class CourseTableViewController: UITableViewController,