From b1451fa944d0d45d74485d042555675a424ac21d Mon Sep 17 00:00:00 2001 From: Joseph Myers Date: Sat, 30 Jun 2018 23:49:44 +0000 Subject: [PATCH 73/73] Python 3 preparation: extract full Content-Type header in roundup_server.py. --- roundup/scripts/roundup_server.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/roundup/scripts/roundup_server.py b/roundup/scripts/roundup_server.py index 100aa27..fe2114c 100644 --- a/roundup/scripts/roundup_server.py +++ b/roundup/scripts/roundup_server.py @@ -376,8 +376,8 @@ class RoundupRequestHandler(http_.server.BaseHTTPRequestHandler): if query: env['QUERY_STRING'] = query if hasattr(self.headers, 'get_content_type'): - # Python 3. - env['CONTENT_TYPE'] = self.headers.get_content_type() + # Python 3. We need the raw header contents. + env['CONTENT_TYPE'] = self.headers.get('content-type') elif self.headers.typeheader is None: # Python 2. env['CONTENT_TYPE'] = self.headers.type -- 2.7.4