             .subscribe(onNext: { [unowned self] in
                 self.newState(state: $0)
             }).addDisposableTo(disposeBag)
-    }
+        
+        tableView.rx.itemSelected
+            .subscribe(onNext: { [unowned self] indexPath in
+                self.tableView.deselectRow(at: indexPath, animated: true)
+                let alias = self.state.sortedHostAliases[indexPath.row]
+                guard let host = self.state.allHosts[alias] else { return }
+                store.dispatch(SelectHost(host: host))
+                
+                self.latestHostUnlockStatus = ""
+                self.selectedCell?.detailTextLabel?.text = ""
+                
+                if let cell = self.tableView.cellForRow(at: indexPath) {
+                    self.updateSelectCell(cell)
+                }
 
-    func editSelectedCell() {
-        editCell(selectedCell)
+            }).addDisposableTo(disposeBag)
     }
     
     fileprivate func editCell(_ cell: UITableViewCell?) {

        
        return [deleteRowAction, editRowAction]
    }

}

        }
        return cell
    }
}

extension MasterViewController { // UITableViewDelegate
    override func tableView(_ tableView: UITableView, editActionsForRowAt indexPath: IndexPath) -> [UITableViewRowAction]? {
        
        let editRowAction = UITableViewRowAction(style: UITableViewRowActionStyle.normal, title: "Edit", handler:{action, indexpath in
