mirror of
https://github.com/encode/django-rest-framework.git
synced 2025-02-16 19:41:06 +03:00
Merge pull request #7481 from smithdc1/app-config
default_app_config application variable is deprecated in Django 3.2
This commit is contained in:
commit
ebc1ebf0c4
|
@ -7,6 +7,8 @@ ______ _____ _____ _____ __
|
|||
\_| \_\____/\____/ \_/ |_| |_| \__,_|_| |_| |_|\___| \_/\_/ \___/|_| |_|\_|
|
||||
"""
|
||||
|
||||
import django
|
||||
|
||||
__title__ = 'Django REST framework'
|
||||
__version__ = '3.12.1'
|
||||
__author__ = 'Tom Christie'
|
||||
|
@ -22,7 +24,9 @@ HTTP_HEADER_ENCODING = 'iso-8859-1'
|
|||
# Default datetime input and output formats
|
||||
ISO_8601 = 'iso-8601'
|
||||
|
||||
default_app_config = 'rest_framework.apps.RestFrameworkConfig'
|
||||
|
||||
if django.VERSION < (3, 2):
|
||||
default_app_config = 'rest_framework.apps.RestFrameworkConfig'
|
||||
|
||||
|
||||
class RemovedInDRF313Warning(DeprecationWarning):
|
||||
|
|
|
@ -1 +1,4 @@
|
|||
default_app_config = 'rest_framework.authtoken.apps.AuthTokenConfig'
|
||||
import django
|
||||
|
||||
if django.VERSION < (3, 2):
|
||||
default_app_config = 'rest_framework.authtoken.apps.AuthTokenConfig'
|
||||
|
|
Loading…
Reference in New Issue
Block a user