forked from ScoDoc/ScoDoc
Modif log en mode TEST
This commit is contained in:
parent
8ca59fe226
commit
48e40e79ba
@ -502,12 +502,10 @@ def clear_scodoc_cache():
|
||||
|
||||
|
||||
# --------- Logging
|
||||
def log(msg: str, silent_test=True):
|
||||
def log(msg: str):
|
||||
"""log a message.
|
||||
If Flask app, use configured logger, else stderr.
|
||||
"""
|
||||
if silent_test and current_app and current_app.config["TESTING"]:
|
||||
return
|
||||
try:
|
||||
dept = getattr(g, "scodoc_dept", "")
|
||||
msg = f" ({dept}) {msg}"
|
||||
|
Loading…
Reference in New Issue
Block a user