Browse Source

Update PreferencesViewController.swift

pull/113/head
Abhishek 3 years ago
parent
commit
bae747283b
  1. 2
      Clocker/Preferences/General/PreferencesViewController.swift

2
Clocker/Preferences/General/PreferencesViewController.swift

@ -489,12 +489,14 @@ extension PreferencesViewController {
// let searchResults = data.decode()
if searchResults.status == ResultStatus.zeroResults {
Logger.info("Zero Results returned")
self.findLocalSearchResultsForTimezones()
self.placeholderLabel.placeholderString = self.searchResultsDataSource.timezoneFilteredArray.isEmpty ? "No results! 😔 Try entering the exact name." : CLEmptyString
self.reloadSearchResults()
self.isActivityInProgress = false
return
} else if searchResults.status == ResultStatus.requestDenied && searchResults.results.isEmpty {
Logger.info("Request denied!")
self.findLocalSearchResultsForTimezones()
self.placeholderLabel.placeholderString = self.searchResultsDataSource.timezoneFilteredArray.isEmpty ? "Update Clocker to get a faster experience 😃" : CLEmptyString
self.reloadSearchResults()

Loading…
Cancel
Save