title: Display searchController on buttonClick
body: <p>i'm trying to show a searchController on buttonClick. However it seem to create an error when the button is clicked. I get an error on the <code>presentViewController</code> row. What am i doing wrong in order to achieve this?</p>
  
  <p>by the way i'm having this code in a <code>tableViewController</code></p>
  
  <pre><code>func searchButtonClicked(sender: UIBarButtonItem) {
      searchController = UISearchController(searchResultsController: self)
     // searchController.searchResultsUpdater = self
      searchController.hidesNavigationBarDuringPresentation = false
      searchController.dimsBackgroundDuringPresentation = false
      self.definesPresentationContext = true
      self.presentViewController(self.searchController, animated: true, completion: nil)
  }
  </code></pre>