Submitter | phabricator |
---|---|
Date | Oct. 8, 2017, 8:38 a.m. |
Message ID | <3229df2f3046044bf10b026b01c9e748@localhost.localdomain> |
Download | mbox | patch |
Permalink | /patch/24638/ |
State | Not Applicable |
Headers | show |
Comments
Patch
diff --git a/mercurial/hgweb/request.py b/mercurial/hgweb/request.py --- a/mercurial/hgweb/request.py +++ b/mercurial/hgweb/request.py @@ -19,6 +19,7 @@ ) from .. import ( + pycompat, util, ) @@ -89,6 +90,8 @@ pass def respond(self, status, type, filename=None, body=None): + if not isinstance(type, str): + type = pycompat.sysstr(type) if self._start_response is not None: self.headers.append(('Content-Type', type)) if filename: