Use "old-style" string format on doc URL redirect.
authorJonathan S. Katz <jonathan.katz@excoventures.com>
Mon, 5 Nov 2018 15:50:14 +0000 (10:50 -0500)
committerJonathan S. Katz <jonathan.katz@excoventures.com>
Mon, 5 Nov 2018 15:50:14 +0000 (10:50 -0500)
This eliminates a unicode error.

pgweb/docs/views.py

index 329351b711070d7c79f12dd248da6932be7f92c6..b800a86649563bb76b2ad05c7f45baebdf8e0fbf 100644 (file)
@@ -73,7 +73,7 @@ def docspermanentredirect(request, version, typ, page, *args):
        """Provides a permanent redirect from the old static/interactive pages to
        the modern pages that do not have said keywords.
        """
-       url = "/docs/{}/".format(version)
+       url = "/docs/%s/" % version
        if page:
                url += page
        return HttpResponsePermanentRedirect(url)