mirror of
https://github.com/psycopg/psycopg2.git
synced 2025-01-31 01:14:09 +03:00
Made changes to drop logging if program is being terminated. Credit to dvarrazzo
This commit is contained in:
parent
f511222705
commit
90cb3bb96a
|
@ -409,7 +409,9 @@ class LoggingConnection(_connection):
|
|||
"""
|
||||
Public interface of the log method defined in initialize
|
||||
"""
|
||||
return self._log()(*args, **kwargs)
|
||||
log = self._log()
|
||||
if log:
|
||||
return self._log()(*args, **kwargs)
|
||||
|
||||
def filter(self, msg, curs):
|
||||
"""Filter the query before logging it.
|
||||
|
|
Loading…
Reference in New Issue
Block a user