mirror of
https://github.com/nocobase/nocobase
synced 2024-11-15 05:46:00 +00:00
fix(logger): fix the issue where workflow log files do not output (#4657)
This commit is contained in:
parent
c2687f71e3
commit
d8e80ecb41
@ -26,7 +26,6 @@ export class PluginActionCustomRequestServer extends Plugin {
|
||||
const logger = this.createLogger({
|
||||
dirname: 'custom-request',
|
||||
filename: '%DATE%.log',
|
||||
transports: [...(process.env.NODE_ENV === 'production' ? ['dailyRotateFile'] : ['console'])],
|
||||
} as LoggerOptions);
|
||||
|
||||
return logger;
|
||||
|
@ -121,9 +121,8 @@ export default class PluginWorkflowServer extends Plugin {
|
||||
}
|
||||
|
||||
const logger = this.createLogger({
|
||||
dirname: path.join('workflows', date),
|
||||
filename: `${workflowId}.log`,
|
||||
transports: [...(process.env.NODE_ENV !== 'production' ? ['console'] : ['file'])],
|
||||
dirname: path.join('workflows', String(workflowId)),
|
||||
filename: '%DATE%.log',
|
||||
} as LoggerOptions);
|
||||
|
||||
this.loggerCache.set(key, logger);
|
||||
|
Loading…
Reference in New Issue
Block a user