From 991cc76d1b52fd072debe04e803d5eb544b36f99 Mon Sep 17 00:00:00 2001 From: Spencer Williams Date: Mon, 7 Apr 2025 22:49:16 -0400 Subject: Validate note type after completion --- lisp/seam.el | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lisp/seam.el b/lisp/seam.el index 6ebdceb..589e947 100644 --- a/lisp/seam.el +++ b/lisp/seam.el @@ -221,7 +221,9 @@ naming. Must be a function taking two arguments: TITLE and TYPE." (defun seam--read-type (prompt arg &optional choices) (when arg (if (listp arg) - (funcall seam-completing-read-function prompt (or choices seam-note-types) nil t) + (let ((type (funcall seam-completing-read-function prompt (or choices seam-note-types) nil t))) + (seam-validate-note-type type) + type) (nth (1- arg) seam-note-types)))) ;;;###autoload -- cgit v1.2.3