mirror of
https://github.com/NapNeko/NapCatQQ.git
synced 2024-11-21 09:36:35 +00:00
fix: ensure cache directory exists
This commit is contained in:
parent
897e5a6f61
commit
405e8d9d92
@ -23,6 +23,7 @@
|
||||
"@types/express": "^4.17.21",
|
||||
"@types/figlet": "^1.5.8",
|
||||
"@types/fluent-ffmpeg": "^2.1.24",
|
||||
"@types/fs-extra": "^11.0.4",
|
||||
"@types/jest": "^29.5.12",
|
||||
"@types/node": "^22.0.1",
|
||||
"@types/qrcode-terminal": "^0.12.2",
|
||||
@ -54,6 +55,7 @@
|
||||
"fast-xml-parser": "^4.3.6",
|
||||
"file-type": "^19.0.0",
|
||||
"fluent-ffmpeg": "^2.1.2",
|
||||
"fs-extra": "^11.2.0",
|
||||
"image-size": "^1.1.1",
|
||||
"json-schema-to-ts": "^3.1.0",
|
||||
"log4js": "^6.9.1",
|
||||
|
@ -6,6 +6,7 @@ import fs from 'fs';
|
||||
import fsPromises from 'fs/promises';
|
||||
import { httpDownload } from '@/common/file';
|
||||
import { randomUUID } from 'crypto';
|
||||
import fsExtra from 'fs-extra';
|
||||
|
||||
export class LaanaFileUtils {
|
||||
cacheDir = path.join(this.laana.pathWrapper.cachePath, 'laana');
|
||||
@ -14,6 +15,7 @@ export class LaanaFileUtils {
|
||||
public core: NapCatCore,
|
||||
public laana: NapCatLaanaAdapter,
|
||||
) {
|
||||
fsExtra.ensureDirSync(this.cacheDir);
|
||||
}
|
||||
|
||||
async resolveCacheIdFromLaanaFile(laanaFile: LaanaFile) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user