mirror of
https://github.com/NapNeko/NapCatQQ.git
synced 2025-12-28 20:31:26 +08:00
fix: #1058
This commit is contained in:
parent
2cc413bec1
commit
5831898c4a
@ -1,13 +1,13 @@
|
||||
import multer from 'multer';
|
||||
import { WebUiConfigWrapper } from '../helper/config';
|
||||
import path from 'path';
|
||||
import fs from 'fs';
|
||||
import type { Request, Response } from 'express';
|
||||
import { WebUiConfig } from '@/webui';
|
||||
|
||||
export const webUIFontStorage = multer.diskStorage({
|
||||
destination: (_, __, cb) => {
|
||||
try {
|
||||
const fontsPath = path.dirname(WebUiConfigWrapper.GetWebUIFontPath());
|
||||
const fontsPath = path.dirname(WebUiConfig.GetWebUIFontPath());
|
||||
// 确保字体目录存在
|
||||
fs.mkdirSync(fontsPath, { recursive: true });
|
||||
cb(null, fontsPath);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user