改回去

This commit is contained in:
Jerry 2025-05-04 10:31:52 +08:00
parent 95b9ef7923
commit f29bd970e8

View File

@ -1,5 +1,5 @@
import System from '../../utils/core/system'; import System from '../../utils/core/system';
import fs from 'fs'; import fs from 'fs/promises';
import logger from '../../utils/core/logger'; import logger from '../../utils/core/logger';
import path from 'path'; import path from 'path';
import paths from '../../utils/core/path'; import paths from '../../utils/core/path';
@ -13,7 +13,7 @@ class SystemService {
public async getRestartTime() { public async getRestartTime() {
logger.debug(`有个小可爱想知道核心重启花了多久..`); logger.debug(`有个小可爱想知道核心重启花了多久..`);
const restartTimePath = path.join(paths.get('temp'), 'restart_time'); const restartTimePath = path.join(paths.get('temp'), 'restart_time');
return fs.readFileSync(restartTimePath, 'utf8'); return await fs.readFile(restartTimePath, 'utf8');
} }
} }