emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/ebdb 57b2514 276/350: Use ebdb-with-record-edits in mor


From: Eric Abrahamsen
Subject: [elpa] externals/ebdb 57b2514 276/350: Use ebdb-with-record-edits in more places
Date: Mon, 14 Aug 2017 11:46:53 -0400 (EDT)

branch: externals/ebdb
commit 57b25147c970ffeb18a8aad60fde0410c6229764
Author: Eric Abrahamsen <address@hidden>
Commit: Eric Abrahamsen <address@hidden>

    Use ebdb-with-record-edits in more places
    
    * ebdb-com.el (ebdb-edit-field, ebdb-delete-field-or-record): I
      believe ebdb-create-record is the only editing command that doesn't
      use this macro now.
---
 ebdb-com.el | 13 +++++++------
 1 file changed, 7 insertions(+), 6 deletions(-)

diff --git a/ebdb-com.el b/ebdb-com.el
index 2d7cca3..d9c74ed 100644
--- a/ebdb-com.el
+++ b/ebdb-com.el
@@ -1638,7 +1638,8 @@ the record, change the name of the record."
   (interactive
    (list (ebdb-current-record)
         (ebdb-current-field)))
-  (eieio-customize-object field)
+  (ebdb-with-record-edits (_r (list record))
+    (eieio-customize-object field))
   (setq ebdb-custom-field-record record))
 
 (cl-defmethod eieio-done-customizing ((_f ebdb-field))
@@ -1731,12 +1732,12 @@ confirm deletion."
   "Delete RECORDS.
 If prefix NOPROMPT is non-nil, do not confirm deletion."
   (interactive (list (ebdb-do-records) current-prefix-arg))
-  (dolist (record (ebdb-record-list records))
+  (ebdb-with-record-edits (r (ebdb-record-list records))
     (when (or noprompt
               (y-or-n-p (format "Delete the EBDB record of %s? "
-                                (ebdb-string record))))
-      (ebdb-delete-record record)
-      (ebdb-redisplay-records record 'remove t))))
+                                (ebdb-string r))))
+      (ebdb-delete-record r)
+      (ebdb-redisplay-records r 'remove t))))
 
 ;;;###autoload
 (defun ebdb-move-records (records db)
@@ -2167,7 +2168,7 @@ just hits return, nil is returned.  Otherwise, a valid 
response is forced."
                     (not (memq record records)))
            (push record records)))
        records))))
-        
+
 
 (defun ebdb-completing-read-record (prompt &optional omit-records)
   "Prompt for and return a single record from the ebdb;



reply via email to

[Prev in Thread] Current Thread [Next in Thread]