fix: Remove threadpool data from logs on production builds

This commit is contained in:
Alex Jbanca 2025-01-10 14:49:17 +02:00 committed by Alex Jbanca
parent 06d549922f
commit 620b37f8a1

View File

@ -53,8 +53,12 @@ proc runTask(safeTaskArg: ThreadSafeTaskArg) {.gcsafe, nimcall, raises: [].} =
let messageType = parsed{"$type"}.getStr let messageType = parsed{"$type"}.getStr
debug "[threadpool task thread] initiating task", messageType=messageType, if defined(production):
threadid=getThreadId(), task=taskArg debug "[threadpool task thread] initiating task", messageType=messageType,
threadid=getThreadId()
else:
debug "[threadpool task thread] initiating task", messageType=messageType,
threadid=getThreadId(), task=taskArg
try: try:
safeTaskArg.tptr(taskArg) safeTaskArg.tptr(taskArg)