Fix sanity check for correct :custom-face format

Instead of testing the length of each form passed to :custom-face,
the sanity check would test the number of forms passed to :custom-face,
causing it to fail when more than 2 face customisations are used.

Fixes https://github.com/jwiegley/use-package/issues/600.

Copyright-paperwork-exempt: yes
This commit is contained in:
wouter bolsterlee 2017-12-20 08:31:56 +01:00
parent 13fb5f4f2e
commit 1fdfd46fb2

View file

@ -1351,7 +1351,7 @@ no keyword implies `:all'."
(spec (nth 1 def)))
(when (or (not face)
(not spec)
(> (length arg) 2))
(> (length def) 2))
(use-package-error error-msg))))))
(defun use-package-handler/:custom-face (name keyword args rest state)