modifié: m/log.py
This commit is contained in:
parent
b8f91861cc
commit
041136659c
5
m/log.py
5
m/log.py
@ -33,6 +33,11 @@ class SingleLevelFilter(logging.Filter):
|
|||||||
"""
|
"""
|
||||||
self.passlevel = passlevel
|
self.passlevel = passlevel
|
||||||
self.reject = reject
|
self.reject = reject
|
||||||
|
def filter(self, record):
|
||||||
|
if self.reject:
|
||||||
|
return (record.levelno != self.passlevel)
|
||||||
|
else:
|
||||||
|
return (record.levelno == self.passlevel)
|
||||||
|
|
||||||
class Log(object):
|
class Log(object):
|
||||||
"""
|
"""
|
||||||
|
Reference in New Issue
Block a user