##// END OF EJS Templates
hgweb: propagate http headers from ErrorResponse for web interface commands...
Sune Foldager -
r38326:519b46a8 default
parent child Browse files
Show More
@@ -441,6 +441,8 b' class hgweb(object):'
441 res.headers['Content-Type'] = ctype
441 res.headers['Content-Type'] = ctype
442 return rctx.sendtemplate('error', error=pycompat.bytestr(e))
442 return rctx.sendtemplate('error', error=pycompat.bytestr(e))
443 except ErrorResponse as e:
443 except ErrorResponse as e:
444 for k, v in e.headers:
445 res.headers[k] = v
444 res.status = statusmessage(e.code, pycompat.bytestr(e))
446 res.status = statusmessage(e.code, pycompat.bytestr(e))
445 res.headers['Content-Type'] = ctype
447 res.headers['Content-Type'] = ctype
446 return rctx.sendtemplate('error', error=pycompat.bytestr(e))
448 return rctx.sendtemplate('error', error=pycompat.bytestr(e))
General Comments 0
You need to be logged in to leave comments. Login now