Show More
@@ -410,15 +410,15 b' class hgwebdir:' | |||||
410 | gc.collect(generation=1) |
|
410 | gc.collect(generation=1) | |
411 |
|
411 | |||
412 | def _runwsgi(self, req, res): |
|
412 | def _runwsgi(self, req, res): | |
413 | try: |
|
413 | self.refresh() | |
414 | self.refresh() |
|
|||
415 |
|
414 | |||
416 |
|
|
415 | csp, nonce = cspvalues(self.ui) | |
417 |
|
|
416 | if csp: | |
418 |
|
|
417 | res.headers[b'Content-Security-Policy'] = csp | |
419 |
|
418 | |||
420 |
|
|
419 | virtual = req.dispatchpath.strip(b'/') | |
421 |
|
|
420 | tmpl = self.templater(req, nonce) | |
|
421 | try: | |||
422 | ctype = tmpl.render(b'mimetype', {b'encoding': encoding.encoding}) |
|
422 | ctype = tmpl.render(b'mimetype', {b'encoding': encoding.encoding}) | |
423 |
|
423 | |||
424 | # Global defaults. These can be overridden by any handler. |
|
424 | # Global defaults. These can be overridden by any handler. |
General Comments 0
You need to be logged in to leave comments.
Login now