branch: externals/denote commit 5d274c825d7b87a3520f8f70c1f2432c7b9ca432 Author: Protesilaos Stavrou <i...@protesilaos.com> Commit: Protesilaos Stavrou <i...@protesilaos.com>
Fix error with denote-journal-extras-title-format=nil We do accept a nil value, as noted in doc string of 'denote-journal-extras-title-format'. Thanks to TJ Stankus for bringing this matter to my attention. It was done in issue 176 on the GitHub mirror: <https://github.com/protesilaos/denote/issues/176>. --- README.org | 6 +++--- denote-journal-extras.el | 6 ++++-- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/README.org b/README.org index 2ac28442a6..9b84cf138f 100644 --- a/README.org +++ b/README.org @@ -4699,9 +4699,9 @@ Denote is meant to be a collective effort. Every bit of help matters. Johan Bolmsjö, Juanjo Presa, Kai von Fintel, Kaushal Modi, M. Hadi Timachi, Mark Olson, Mirko Hernandez, Niall Dooley, Paul van Gelder, Peter Prevos, Shreyas Ragavan, Stefan Thesing, Summer Emacs, Sven - Seebeck, Taoufik, Viktor Haag, Wade Mealing, Yi Liu, Ypot, atanasj, - doolio, drcxd, hpgisler, pRot0ta1p, rbenit68, relict007, sienic, - sundar bp. + Seebeck, Taoufik, TJ Stankus, Viktor Haag, Wade Mealing, Yi Liu, + Ypot, atanasj, doolio, drcxd, hpgisler, pRot0ta1p, rbenit68, + relict007, sienic, sundar bp. Special thanks to Peter Povinec who helped refine the file-naming scheme, which is the cornerstone of this project. diff --git a/denote-journal-extras.el b/denote-journal-extras.el index 6531b33dad..c9c26edc74 100644 --- a/denote-journal-extras.el +++ b/denote-journal-extras.el @@ -111,9 +111,11 @@ journal entry (refer to the `tmr' package on GNU ELPA)." (defun denote-journal-extras-daily--title-format () "Return `denote-journal-extras-title-format' or prompt for title." (cond - ((stringp denote-journal-extras-title-format) + ((and denote-journal-extras-title-format + (stringp denote-journal-extras-title-format)) (format-time-string denote-journal-extras-title-format)) - ((symbolp denote-journal-extras-title-format) + ((and (symbolp denote-journal-extras-title-format) + (not (null denote-journal-extras-title-format))) (format-time-string (pcase denote-journal-extras-title-format ('day "%A")