mirror of
https://github.com/whyour/qinglong.git
synced 2026-02-12 22:16:42 +08:00
Fix uniqPath calculation in runSingle for null log_name
Co-authored-by: whyour <22700758+whyour@users.noreply.github.com>
This commit is contained in:
parent
fbad538db2
commit
11ec1041c7
|
|
@ -509,7 +509,7 @@ export default class CronService {
|
||||||
const uniqPath =
|
const uniqPath =
|
||||||
log_name === '/dev/null'
|
log_name === '/dev/null'
|
||||||
? await getUniqPath(command, `${id}`)
|
? await getUniqPath(command, `${id}`)
|
||||||
: log_name;
|
: log_name || (await getUniqPath(command, `${id}`));
|
||||||
const logTime = dayjs().format('YYYY-MM-DD-HH-mm-ss-SSS');
|
const logTime = dayjs().format('YYYY-MM-DD-HH-mm-ss-SSS');
|
||||||
const logDirPath = path.resolve(config.logPath, `${uniqPath}`);
|
const logDirPath = path.resolve(config.logPath, `${uniqPath}`);
|
||||||
await fs.mkdir(logDirPath, { recursive: true });
|
await fs.mkdir(logDirPath, { recursive: true });
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user