Correct the usage of `image-file-name-regexps'

* lisp/image-file.el (image-file-name-regexp): Treat
`image-file-name-regexps' as a list of regexps (as documented) in
addition to a regexp string (bug#57971).

Copyright-paperwork-exempt: yes
This commit is contained in:
Thuna 2022-09-21 13:51:53 +02:00 committed by Lars Ingebrigtsen
parent 3ed9a1b0be
commit 7a36828dc3

View file

@ -91,9 +91,10 @@ the variable is set using \\[customize]."
"\\'"))))
(mapconcat
#'identity
(delq nil (list exts-regexp
image-file-name-regexps
(car (rassq 'imagemagick image-type-file-name-regexps))))
(delq nil
(nconc (list exts-regexp
(car (rassq 'imagemagick image-type-file-name-regexps)))
(ensure-list image-file-name-regexps)))
"\\|")))