Skip to content

Commit 55ee588

Browse files
committed
Use default reason phrases from HTTP standard.
Closes #2763
1 parent ac77a56 commit 55ee588

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

rest_framework/response.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
The appropriate renderer is called during Django's template response rendering.
66
"""
77
from __future__ import unicode_literals
8-
from django.core.handlers.wsgi import STATUS_CODE_TEXT
8+
from django.utils.six.moves.http_client import responses
99
from django.template.response import SimpleTemplateResponse
1010
from django.utils import six
1111

@@ -77,7 +77,7 @@ def status_text(self):
7777
"""
7878
# TODO: Deprecate and use a template tag instead
7979
# TODO: Status code text for RFC 6585 status codes
80-
return STATUS_CODE_TEXT.get(self.status_code, '')
80+
return responses.get(self.status_code, '')
8181

8282
def __getstate__(self):
8383
"""

0 commit comments

Comments
 (0)