branch: externals/ebdb
commit db53550d813b205146b2a104a6ca4c5b90c97c43
Author: Eric Abrahamsen <[email protected]>
Commit: Eric Abrahamsen <[email protected]>
Protect against bug with timestamp/creation-dates
The real solution will involve fixing initialize-instance for records
so that the timestamp/creation-date are installed no matter what.
* ebdb-format.el (ebdb-fmt-collect-fields): Stop-gap protection
against missing creation-date and timestamp fields.
* ebdb.el: Bump to 0.3.5
---
ebdb-format.el | 7 ++++++-
ebdb.el | 2 +-
2 files changed, 7 insertions(+), 2 deletions(-)
diff --git a/ebdb-format.el b/ebdb-format.el
index 0ef16cf..e17fa29 100644
--- a/ebdb-format.el
+++ b/ebdb-format.el
@@ -250,7 +250,12 @@ FIELD-STRING1 FIELD-STRING2 ..)."
field-list
(mapcar #'cdr
(seq-remove
- (lambda (elt) (eql (car elt) 'name))
+ ;; The or (null (cdr elt)) is there to
+ ;; protect against an earlier bug with
+ ;; timestamps and creation-dates, it could
+ ;; be removed at some point.
+ (lambda (elt) (or (eql (car elt) 'name)
+ (null (cdr elt))))
(ebdb-record-current-fields record nil t)))))
f-class)
(with-slots (exclude include) fmt
diff --git a/ebdb.el b/ebdb.el
index 3fc86bb..26c3b67 100644
--- a/ebdb.el
+++ b/ebdb.el
@@ -2,7 +2,7 @@
;; Copyright (C) 2016-2017 Free Software Foundation, Inc.
-;; Version: 0.3.4
+;; Version: 0.3.5
;; Package-Requires: ((emacs "25.1") (cl-lib "0.5") (seq "2.15"))
;; Maintainer: Eric Abrahamsen <[email protected]>