 extension MainViewController: AutocompleteViewControllerDelegate {
     
     func autocomplete(selectedSuggestion suggestion: String) {
+        dismissOmniBar()
         loadQueryInCurrentTab(query: suggestion)
-        omniBar?.resignFirstResponder()
     }
     
     func autocomplete(pressedPlusButtonForSuggestion suggestion: String) {

    
    private func dismissAutcompleteSuggestions() {
        guard let controller = autocompleteController else { return }
        controller.view.removeFromSuperview()
        controller.removeFromParentViewController()
        autocompleteController = nil
    }
    
    @IBAction func onBackPressed(_ sender: UIBarButtonItem) {

    }
    
    fileprivate func dismissOmniBar() {
        omniBar?.resignFirstResponder()
        dismissAutcompleteSuggestions()
        refreshOmniText()
        currentTab?.omniBarWasDismissed()
