actually import _mysql_exceptions before trying to test against it
This commit is contained in:
parent
dc215a5d01
commit
fb206dfde6
|
@ -962,6 +962,7 @@ class fpdb:
|
|||
if self.db!=None:
|
||||
if self.db.backend==self.db.MYSQL_INNODB:
|
||||
try:
|
||||
import _mysql_exceptions
|
||||
if self.db is not None and self.db.is_connected():
|
||||
self.db.disconnect()
|
||||
except _mysql_exceptions.OperationalError: # oh, damn, we're already disconnected
|
||||
|
|
Loading…
Reference in New Issue
Block a user