mercurial/hgweb/hgwebdir_mod.py
changeset 45213 d5ccc059fbcd
parent 45201 86f9b25d750b
child 45306 9a5c4875a88c
--- a/mercurial/hgweb/hgwebdir_mod.py	Wed Jul 22 00:09:17 2020 -0700
+++ b/mercurial/hgweb/hgwebdir_mod.py	Fri Jul 24 11:24:59 2020 -0700
@@ -415,7 +415,8 @@
                 static = self.ui.config(b"web", b"static", untrusted=False)
                 if not static:
                     tp = self.templatepath or templater.templatedir()
-                    static = [os.path.join(tp, b'static')]
+                    if tp is not None:
+                        static = [os.path.join(tp, b'static')]
 
                 staticfile(static, fname, res)
                 return res.sendresponse()