summaryrefslogtreecommitdiff
path: root/django/db/backends/__init__.py
diff options
context:
space:
mode:
Diffstat (limited to 'django/db/backends/__init__.py')
-rw-r--r--django/db/backends/__init__.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/django/db/backends/__init__.py b/django/db/backends/__init__.py
index 0c328a50c8..dfc967e60a 100644
--- a/django/db/backends/__init__.py
+++ b/django/db/backends/__init__.py
@@ -158,7 +158,7 @@ class BaseDatabaseWrapper(object):
(self.use_debug_cursor is None and settings.DEBUG)):
cursor = self.make_debug_cursor(self._cursor())
else:
- cursor = utils.CursorWrapper(self._cursor(), self)
+ cursor = self.make_cursor(self._cursor())
return cursor
def commit(self):
@@ -433,6 +433,12 @@ class BaseDatabaseWrapper(object):
"""
return utils.CursorDebugWrapper(cursor, self)
+ def make_cursor(self, cursor):
+ """
+ Creates a cursor without debug logging.
+ """
+ return utils.CursorWrapper(cursor, self)
+
@contextmanager
def temporary_connection(self):
"""