         }
     }
     
-    @objc fileprivate func toggleEditMode(_ sender: UIBarButtonItem) {
+    @objc
+    fileprivate func toggleEditMode(_ sender: UIBarButtonItem) {
         isEditMode.toggle()
     }
     

    @objc
    fileprivate func toggleDelete(sender: UIBarButtonItem) {
        let alertController = UIAlertController(title: nil, message: nil, preferredStyle: .actionSheet)
        let actionDelete = UIAlertAction(title: "Delete all", style: .destructive) { [unowned self] _ in
            self.deleteAll()
        }
        let actionDeleteSelected = UIAlertAction(title: "Delete selected", style: .destructive) { [unowned self] _ in
            guard let selectedRows = self.viewRealm.tableView.indexPathsForSelectedRows,
                let objects = self.objects, objects.isNonEmpty else { return }
            let results = selectedRows.map { objects[$0.row] }
            self.engine.deleteObjects(objects: results)
        }

        guard objects?.isNonEmpty == true else { return }
        selectAll.toggle()
        isEditMode = true
        let last = viewRealm.tableView.numberOfRows(inSection: 0) - 1
        let range = Range(uncheckedBounds: (0, last))
        let selectedRows = range.map { IndexPath(item: $0, section: 0) }
        if selectAll {
