mirror of
https://github.com/whyour/qinglong.git
synced 2026-08-15 13:47:11 +08:00
修复新建文件
This commit is contained in:
+3
-1
@@ -81,7 +81,9 @@ export default (app: Router) => {
|
|||||||
data: '文件路径禁止访问',
|
data: '文件路径禁止访问',
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
if (!originFilename) {
|
||||||
|
originFilename = filename;
|
||||||
|
}
|
||||||
const originFilePath = `${path}${originFilename.replace(/\//g, '')}`;
|
const originFilePath = `${path}${originFilename.replace(/\//g, '')}`;
|
||||||
const filePath = `${path}${filename.replace(/\//g, '')}`;
|
const filePath = `${path}${filename.replace(/\//g, '')}`;
|
||||||
if (fs.existsSync(originFilePath)) {
|
if (fs.existsSync(originFilePath)) {
|
||||||
|
|||||||
Reference in New Issue
Block a user