     override func viewDidLoad() {
         super.viewDidLoad()
         // Do any additional setup after loading the view, typically from a nib.
-        self.navigationItem.leftBarButtonItem = UIBarButtonItem(barButtonSystemItem: .edit, target: self, action: #selector(editSelectedCell))
-
+        let editButtonItem = UIBarButtonItem(barButtonSystemItem: .edit, target: nil, action: nil)
+        editButtonItem.rx.tap.subscribe(onNext: { [unowned self] in
+            self.editCell(self.selectedCell)
+        }).addDisposableTo(disposeBag)
+        self.navigationItem.leftBarButtonItem = editButtonItem
         
         let infoButton = UIButton(type: .infoLight)
         infoButton.rx.tap.subscribe(onNext: {

        
        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
