forked from orbit-oss/flask
Changed logic for debug level log settings
This commit is contained in:
parent
583c5f7935
commit
61a95196ac
3 changed files with 12 additions and 1 deletions
|
|
@ -25,7 +25,9 @@ def create_logger(app):
|
|||
|
||||
class DebugLogger(Logger):
|
||||
def getEffectiveLevel(x):
|
||||
return DEBUG if app.debug else Logger.getEffectiveLevel(x)
|
||||
if x.level == 0 and app.debug:
|
||||
return DEBUG
|
||||
return Logger.getEffectiveLevel(x)
|
||||
|
||||
class DebugHandler(StreamHandler):
|
||||
def emit(x, record):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue