Browse Source

ox-latex/beamer: Fix reported error when no suitable class is found

* lisp/ox-beamer.el (org-beamer-template): Add missing `class'
argument for `format-string'.
* lisp/ox-latex.el (org-latex-template): Add missing `class' argument
for `format-string'.

Thanks to Sébastien Vauban for reporting the problem and providing the
initial patch.
Nicolas Goaziou 5 years ago
parent
commit
5bceb62142
2 changed files with 2 additions and 2 deletions
  1. 1 1
      lisp/ox-beamer.el
  2. 1 1
      lisp/ox-latex.el

+ 1 - 1
lisp/ox-beamer.el

@@ -844,7 +844,7 @@ holding export options."
 			"^[ \t]*\\\\documentclass\\(\\(\\[.*\\]\\)?\\)"
 			class-options header t nil 1)))))
 	  (if (not document-class-string)
-	      (user-error "Unknown LaTeX class `%s'")
+	      (user-error "Unknown LaTeX class `%s'" class)
 	    (org-latex-guess-babel-language
 	     (org-latex-guess-inputenc
 	      (org-splice-latex-header

+ 1 - 1
lisp/ox-latex.el

@@ -1112,7 +1112,7 @@ holding export options."
 			"^[ \t]*\\\\documentclass\\(\\(\\[.*\\]\\)?\\)"
 			class-options header t nil 1)))))
 	  (if (not document-class-string)
-	      (user-error "Unknown LaTeX class `%s'")
+	      (user-error "Unknown LaTeX class `%s'" class)
 	    (org-latex-guess-babel-language
 	     (org-latex-guess-inputenc
 	      (org-splice-latex-header