mirror of
https://github.com/encode/django-rest-framework.git
synced 2024-11-11 04:07:39 +03:00
This commit is contained in:
parent
5009aeff18
commit
2b6245db53
|
@ -27,7 +27,7 @@ class CreateModelMixin(object):
|
||||||
|
|
||||||
def get_success_headers(self, data):
|
def get_success_headers(self, data):
|
||||||
try:
|
try:
|
||||||
return {'Location': data[api_settings.URL_FIELD_NAME]}
|
return {'Location': str(data[api_settings.URL_FIELD_NAME])}
|
||||||
except (TypeError, KeyError):
|
except (TypeError, KeyError):
|
||||||
return {}
|
return {}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user