file path error

This commit is contained in:
CHIEFSOFT\ameye
2024-04-13 07:25:04 -04:00
parent f91473fe32
commit c5a9b63086
+1 -1
View File
@@ -74,7 +74,7 @@ app.post('/upload/task', upload.single('file'), (req, res) => {
}
const oldPath = req.file.path;
const newPath = dir + req.file.filename;
const newPath = dir + "/" + req.file.filename;
fs.rename(oldPath, newPath, function (err) {
if (err) throw err