bug fix in log.fail()

The value of the callback needs to be returned.  In particular,
this allows the error to be passed along.
This commit is contained in:
Job Evers-Meltzer 2016-12-29 22:37:47 -06:00
parent ccfb1f3921
commit 689ac431d3

View file

@ -369,7 +369,7 @@ class Logger(logging.Logger):
self.name, level, fn, lno, msg, msg_args, exc_info, func, msg_kwargs)
self.handle(record)
if callback:
callback(err, *args, **kwargs)
return callback(err, *args, **kwargs)
return _fail
def trace(self, msg, *args, **kwargs):