Fix showing of admin reset link also in devserver where the logging configuration was eating the message.
This commit is contained in:
@@ -14,6 +14,19 @@ from paskia.util import hostutil
|
|||||||
|
|
||||||
logger = logging.getLogger(__name__)
|
logger = logging.getLogger(__name__)
|
||||||
|
|
||||||
|
|
||||||
|
def _configure_logger() -> None:
|
||||||
|
if logger.handlers:
|
||||||
|
return
|
||||||
|
handler = logging.StreamHandler()
|
||||||
|
handler.setFormatter(logging.Formatter("%(message)s"))
|
||||||
|
logger.addHandler(handler)
|
||||||
|
logger.setLevel(logging.INFO)
|
||||||
|
logger.propagate = False
|
||||||
|
|
||||||
|
|
||||||
|
_configure_logger()
|
||||||
|
|
||||||
# Shared log message template for admin reset links
|
# Shared log message template for admin reset links
|
||||||
ADMIN_RESET_MESSAGE = """
|
ADMIN_RESET_MESSAGE = """
|
||||||
👤 Admin %s
|
👤 Admin %s
|
||||||
|
|||||||
Reference in New Issue
Block a user