MICountryPicker
MICountryPicker copied to clipboard
Wrong title for header in section
When we enter some text in search bar:
I propose:
override open func tableView(_ tableView: UITableView, titleForHeaderInSection section: Int) -> String? {
if (searchController.searchBar.text?.characters.count)! > 0 {
return searchController.searchBar.text // Or only the first character ??
}
if !sections[section].countries.isEmpty {
return self.collation.sectionTitles[section] as String
}
return ""
}