diff --git a/docs/_exts/redirects.py b/docs/_exts/redirects.py index 90d69efee5f..1adf3cdb8ab 100644 --- a/docs/_exts/redirects.py +++ b/docs/_exts/redirects.py @@ -6,8 +6,8 @@ def create_redirect(dst): tpl = '' return tpl.format(dst) -def create_redirects(app, docname): - if not app.builder.name == 'html': +def create_redirects(app, exception): + if exception is not None or not app.builder.name == 'html': return for src, dst in app.config.html_redirects: path = os.path.join(app.outdir, '{0}.html'.format(src))