     
     public func updateSearchResults(for searchController: UISearchController) {
         if let searchText = searchController.searchBar.text {
-            print("Search Text: \(searchText)")
-            // todo: get data here
+            self.searchText = searchText
+            getEventsForSearch(searchText: searchText)
         }
         
     }

    
    let searchController = UISearchController(searchResultsController: nil)
    var events: [Event]?

    override func viewDidLoad() {
        super.viewDidLoad()


    public func didDismissSearchController(_ searchController: UISearchController) {
        // When cancelled show the previous data set
        searchedEvents = []
        searchText = nil
        tableView.reloadData()
    }
    
    // MARK: - Network call
