Merge branch 'bugfix'

This commit is contained in:
Ihor Radchenko 2023-12-12 16:15:08 +01:00
commit b9778ed5ad
No known key found for this signature in database
GPG Key ID: 6470762A7DA11D8B
1 changed files with 13 additions and 8 deletions

View File

@ -41,14 +41,19 @@
(defun org-entities--user-safe-p (v) (defun org-entities--user-safe-p (v)
"Non-nil if V is a safe value for `org-entities-user'." "Non-nil if V is a safe value for `org-entities-user'."
(pcase v (cond
(`nil t) ((not v) t)
(`(,(and (pred stringp) ((listp v)
(pred (string-match-p "\\`[a-zA-Z][a-zA-Z0-9]*\\'"))) (seq-every-p
,(pred stringp) ,(pred booleanp) ,(pred stringp) (lambda (e)
,(pred stringp) ,(pred stringp) ,(pred stringp)) (pcase e
t) (`(,(and (pred stringp)
(_ nil))) (pred (string-match-p "\\`[a-zA-Z][a-zA-Z0-9]*\\'")))
,(pred stringp) ,(pred booleanp) ,(pred stringp)
,(pred stringp) ,(pred stringp) ,(pred stringp))
t)
(_ nil)))
v))))
(defcustom org-entities-user nil (defcustom org-entities-user nil
"User-defined entities used in Org to produce special characters. "User-defined entities used in Org to produce special characters.