mirror of
https://github.com/django/django.git
synced 2025-08-24 04:24:34 +00:00
Made sure cursor.close() does not complain if cursor is already closed on Oracle
Refs #22483
This commit is contained in:
parent
25209715d4
commit
53d97e4fe3
1 changed files with 7 additions and 0 deletions
|
@ -917,6 +917,13 @@ class FormatStylePlaceholderCursor(object):
|
|||
def fetchall(self):
|
||||
return tuple(_rowfactory(r, self.cursor) for r in self.cursor.fetchall())
|
||||
|
||||
def close(self):
|
||||
try:
|
||||
self.cursor.close()
|
||||
except Database.InterfaceError:
|
||||
# already closed
|
||||
pass
|
||||
|
||||
def var(self, *args):
|
||||
return VariableWrapper(self.cursor.var(*args))
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue