mirror of
https://github.com/nocobase/nocobase
synced 2024-11-15 09:38:51 +00:00
chore: system logger with error stack (#3747)
This commit is contained in:
parent
aa1823cd73
commit
a81fa5b8e0
@ -49,11 +49,12 @@ class SystemLoggerTransport extends Transport {
|
||||
}
|
||||
|
||||
log(info: any, callback: any) {
|
||||
const { level, message, reqId, app, [SPLAT]: args } = info;
|
||||
const { level, message, reqId, app, stack, [SPLAT]: args } = info;
|
||||
const logger = level === 'error' && this.errorLogger ? this.errorLogger : this.logger;
|
||||
const { module, submodule, method, ...meta } = args?.[0] || {};
|
||||
logger.log({
|
||||
level,
|
||||
stack,
|
||||
message,
|
||||
meta,
|
||||
module: module || info['module'] || '',
|
||||
|
Loading…
Reference in New Issue
Block a user