mirror of
https://github.com/NapNeko/NapCatQQ.git
synced 2025-07-19 12:03:37 +00:00
fix: error
This commit is contained in:
@@ -314,7 +314,15 @@ export async function NCoreInitShell() {
|
|||||||
await initializeSession(session, sessionConfig);
|
await initializeSession(session, sessionConfig);
|
||||||
|
|
||||||
const accountDataPath = path.resolve(dataPath, './NapCat/data');
|
const accountDataPath = path.resolve(dataPath, './NapCat/data');
|
||||||
fs.mkdirSync(dataPath, { recursive: true });
|
//判断dataPath是否为根目录 或者 D:/ 之类的盘目录
|
||||||
|
if (dataPath !== '/' && /^[a-zA-Z]:\\$/.test(dataPath) === false) {
|
||||||
|
try {
|
||||||
|
fs.mkdirSync(accountDataPath, { recursive: true });
|
||||||
|
} catch (error) {
|
||||||
|
logger.logError('创建accountDataPath失败', error);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
logger.logDebug('本账号数据/缓存目录:', accountDataPath);
|
logger.logDebug('本账号数据/缓存目录:', accountDataPath);
|
||||||
|
|
||||||
await new NapCatShell(
|
await new NapCatShell(
|
||||||
|
Reference in New Issue
Block a user