1
0
mirror of https://github.com/django/django.git synced 2025-10-24 06:06:09 +00:00

Converted request.META['REQUEST_METHOD'] calls to request.method, throughout the Django codebase

git-svn-id: http://code.djangoproject.com/svn/django/trunk@3171 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Adrian Holovaty
2006-06-20 04:34:13 +00:00
parent b93de6a2cb
commit 37addba352
7 changed files with 10 additions and 11 deletions

View File

@@ -68,7 +68,7 @@ class WSGIRequest(http.HttpRequest):
def _load_post_and_files(self):
# Populates self._post and self._files
if self.environ['REQUEST_METHOD'] == 'POST':
if self.method == 'POST':
if self.environ.get('CONTENT_TYPE', '').startswith('multipart'):
header_dict = dict([(k, v) for k, v in self.environ.items() if k.startswith('HTTP_')])
header_dict['Content-Type'] = self.environ.get('CONTENT_TYPE', '')