summaryrefslogtreecommitdiff
path: root/django/db/backends/oracle/schema.py
diff options
context:
space:
mode:
authorShai Berger <shai@platonix.com>2014-05-28 20:40:31 +0300
committerTim Graham <timograham@gmail.com>2014-06-13 13:09:51 -0400
commit06c0e740a41f64a49a11569e76edee7be04770e0 (patch)
treec99c372ecc879a4f937608600b7573440456b51f /django/db/backends/oracle/schema.py
parent50b9313e0a0739dfe1ac699449b66ed3e62add51 (diff)
downloaddjango-06c0e740a41f64a49a11569e76edee7be04770e0.tar.gz
Added django.utils.six.buffer_types
and used it in the Oracle SchemaEditor. Refs #22715.
Diffstat (limited to 'django/db/backends/oracle/schema.py')
-rw-r--r--django/db/backends/oracle/schema.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/django/db/backends/oracle/schema.py b/django/db/backends/oracle/schema.py
index 986cd95e75..702b3791d0 100644
--- a/django/db/backends/oracle/schema.py
+++ b/django/db/backends/oracle/schema.py
@@ -24,8 +24,7 @@ class DatabaseSchemaEditor(BaseDatabaseSchemaEditor):
return "'%s'" % value
elif isinstance(value, six.string_types):
return "'%s'" % six.text_type(value).replace("\'", "\'\'")
- elif (isinstance(value, six.memoryview) or
- six.PY3 and isinstance(value, bytes)):
+ elif isinstance(value, six.buffer_types):
return "'%s'" % force_text(binascii.hexlify(value))
elif isinstance(value, bool):
return "1" if value else "0"