branch: master commit 00f9192bbbfbc1ecfc784f5a1b8c5e9880d7d44a Author: Arash Esbati <ar...@gnu.org> Commit: Arash Esbati <ar...@gnu.org>
Check the value of `LaTeX-current-environment' first * style/breqn.el (LaTeX-breqn-key-val-options): Check if the variable `LaTeX-current-environment' contains a name before running the function of the same name. --- style/breqn.el | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/style/breqn.el b/style/breqn.el index bdca5283..9b2ae933 100644 --- a/style/breqn.el +++ b/style/breqn.el @@ -66,7 +66,8 @@ The keys \"label\" and \"labelprefix\" are omitted.") (defun LaTeX-breqn-key-val-options () "Return updated key=val's based on the current \"breqn\" environment." - (let ((currenv (LaTeX-current-environment))) + (let ((currenv (or LaTeX-current-environment + (LaTeX-current-environment)))) (cond ((string-match-p "\\`dgroup" currenv) (append '(("noalign") ("brace")) LaTeX-breqn-key-val-options))