mirror of
https://github.com/Sebclem/hassio-nextcloud-backup.git
synced 2024-11-05 00:52:59 +01:00
🚑 Fix crash on restore if tmp folder not exist #28
This commit is contained in:
parent
8632a3d079
commit
d888ca7b3d
@ -298,7 +298,7 @@ class WebdavTools {
|
||||
statusTools.setStatus(status);
|
||||
|
||||
logger.info("Downloading backup...");
|
||||
|
||||
if (!fs.existsSync("./temp/")) fs.mkdirSync("./temp/");
|
||||
let tmpFile = `./temp/restore_${moment().format("MMM-DD-YYYY_HH_mm")}.tar`;
|
||||
let stream = fs.createWriteStream(tmpFile);
|
||||
let conf = this.getConf();
|
||||
|
Loading…
Reference in New Issue
Block a user