From b9fe829e026e8d3cfaf774dfc8144d3dc2239e69 Mon Sep 17 00:00:00 2001 From: Georg Brandl Date: Tue, 6 Jan 2015 17:10:43 +0100 Subject: [PATCH] highlighting: fix potential TypeError --- sphinx/highlighting.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sphinx/highlighting.py b/sphinx/highlighting.py index 63a46fbd71..58365b35c5 100644 --- a/sphinx/highlighting.py +++ b/sphinx/highlighting.py @@ -164,7 +164,7 @@ class PygmentsBridge(object): lexer = lexers[lang] else: try: - lexer = lexers[lang] = get_lexer_by_name(lang, **opts) + lexer = lexers[lang] = get_lexer_by_name(lang, **opts or {}) except ClassNotFound: if warn: warn('Pygments lexer name %r is not known' % lang)