File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -58,7 +58,7 @@ def chunked_cursor(*args, **kwargs):
58
58
# prevent double wrapping
59
59
# solves https://github.com/jazzband/django-debug-toolbar/issues/1239
60
60
cursor = connection ._djdt_chunked_cursor (* args , ** kwargs )
61
- if not isinstance (cursor , state . Wrapper ):
61
+ if not isinstance (cursor , BaseCursorWrapper ):
62
62
return state .Wrapper (cursor , connection , panel )
63
63
return cursor
64
64
@@ -74,7 +74,11 @@ def unwrap_cursor(connection):
74
74
del connection .chunked_cursor
75
75
76
76
77
- class ExceptionCursorWrapper :
77
+ class BaseCursorWrapper :
78
+ pass
79
+
80
+
81
+ class ExceptionCursorWrapper (BaseCursorWrapper ):
78
82
"""
79
83
Wraps a cursor and raises an exception on any operation.
80
84
Used in Templates panel.
@@ -87,7 +91,7 @@ def __getattr__(self, attr):
87
91
raise SQLQueryTriggered ()
88
92
89
93
90
- class NormalCursorWrapper :
94
+ class NormalCursorWrapper ( BaseCursorWrapper ) :
91
95
"""
92
96
Wraps a cursor and logs queries.
93
97
"""
You can’t perform that action at this time.
0 commit comments