aboutsummaryrefslogtreecommitdiffstats
path: root/rest_framework/fields.py
diff options
context:
space:
mode:
authorXavier Ordoquy2013-01-03 11:41:07 +0100
committerXavier Ordoquy2013-01-03 11:41:07 +0100
commit60250f22c8e144494f372338c16a2167cccb319d (patch)
treea467ab51837175ab29abec7eb22bb936375763da /rest_framework/fields.py
parentcf51dcc9bb409fb985d5aa09c426d1ed33f6e9b4 (diff)
downloaddjango-rest-framework-60250f22c8e144494f372338c16a2167cccb319d.tar.bz2
Move the various compat things to the compat module.
Diffstat (limited to 'rest_framework/fields.py')
-rw-r--r--rest_framework/fields.py7
1 files changed, 2 insertions, 5 deletions
diff --git a/rest_framework/fields.py b/rest_framework/fields.py
index e59cc9b4..adea5bf5 100644
--- a/rest_framework/fields.py
+++ b/rest_framework/fields.py
@@ -1,6 +1,5 @@
from __future__ import unicode_literals
-import six
import copy
import datetime
@@ -14,14 +13,12 @@ from django.conf import settings
from django import forms
from django.forms import widgets
from django.utils.encoding import is_protected_type
-try:
- from django.utils.encoding import smart_text
-except ImportError:
- from django.utils.encoding import smart_unicode as smart_text
from django.utils.translation import ugettext_lazy as _
from rest_framework.compat import parse_date, parse_datetime
from rest_framework.compat import timezone
from rest_framework.compat import BytesIO
+from rest_framework.compat import six
+from rest_framework.compat import smart_text
def is_simple_callable(obj):