aboutsummaryrefslogtreecommitdiffstats
path: root/rest_framework/settings.py
diff options
context:
space:
mode:
authorTom Christie2013-02-04 20:37:09 +0000
committerTom Christie2013-02-04 20:37:09 +0000
commit8e846bdf52f03d0733ac73e418152800e582b898 (patch)
treecd7034d5573f1e264798a618c88addc4d2f45ce0 /rest_framework/settings.py
parentd9b73e15c87c3a7f11d6bea5ffd6118f86e40051 (diff)
parent97f2b994951605ffdef08159be450d1e77762bf9 (diff)
downloaddjango-rest-framework-8e846bdf52f03d0733ac73e418152800e582b898.tar.bz2
Merge branch 'py3k' into 2.2
Conflicts: rest_framework/relations.py rest_framework/serializers.py rest_framework/tests/relations_hyperlink.py rest_framework/tests/relations_slug.py
Diffstat (limited to 'rest_framework/settings.py')
-rw-r--r--rest_framework/settings.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/rest_framework/settings.py b/rest_framework/settings.py
index 5c77c55c..b3ca0134 100644
--- a/rest_framework/settings.py
+++ b/rest_framework/settings.py
@@ -19,6 +19,7 @@ back to the defaults.
"""
from django.conf import settings
from django.utils import importlib
+from rest_framework.compat import six
USER_SETTINGS = getattr(settings, 'REST_FRAMEWORK', None)
@@ -98,7 +99,7 @@ def perform_import(val, setting_name):
If the given setting is a string import notation,
then perform the necessary import or imports.
"""
- if isinstance(val, basestring):
+ if isinstance(val, six.string_types):
return import_from_string(val, setting_name)
elif isinstance(val, (list, tuple)):
return [import_from_string(item, setting_name) for item in val]