1
0
Fork 0

Do not insert a list element if no insert prompt is needed

This commit is contained in:
Bram Schoenmakers 2024-02-03 07:00:46 +01:00
parent 6996098c1d
commit e409be20b4
Signed by: bram
GPG key ID: 0CCD19DFDC63258F

10
kagi.el
View file

@ -529,11 +529,11 @@ defined in `kagi--summarizer-engines'."
Not all commands need to insert a summary, so only prompt for
this when PROMPT-INSERT-P is non-nil."
(append
(list
(and prompt-insert-p
(equal current-prefix-arg '(4))
(not buffer-read-only)
(y-or-n-p "Insert summary at point?")))
(when prompt-insert-p
(list
(and (equal current-prefix-arg '(4))
(not buffer-read-only)
(y-or-n-p "Insert summary at point?"))))
(list
(when (equal current-prefix-arg '(4))
(let ((language-table (mapcar (lambda (lang)