mirror of
https://github.com/Sebclem/hassio-nextcloud-backup.git
synced 2024-11-22 17:22:58 +01:00
🚑 Fix crash if SSL is disable #43
This commit is contained in:
parent
768ae1d97f
commit
46ae0b7a77
@ -228,6 +228,7 @@ class WebdavTools {
|
|||||||
options["https"] = { rejectUnauthorized: conf.self_signed === "false" };
|
options["https"] = { rejectUnauthorized: conf.self_signed === "false" };
|
||||||
}
|
}
|
||||||
logger.debug(`...URI: ${encodeURI(this.baseUrl.replace(this.host, 'host.hiden') + path)}`);
|
logger.debug(`...URI: ${encodeURI(this.baseUrl.replace(this.host, 'host.hiden') + path)}`);
|
||||||
|
if (conf.ssl === "true")
|
||||||
logger.debug(`...rejectUnauthorized: ${options["https"]["rejectUnauthorized"]}`);
|
logger.debug(`...rejectUnauthorized: ${options["https"]["rejectUnauthorized"]}`);
|
||||||
|
|
||||||
got.stream
|
got.stream
|
||||||
@ -327,6 +328,7 @@ class WebdavTools {
|
|||||||
options["https"] = { rejectUnauthorized: conf.self_signed === "false" };
|
options["https"] = { rejectUnauthorized: conf.self_signed === "false" };
|
||||||
}
|
}
|
||||||
logger.debug(`...URI: ${encodeURI(this.baseUrl.replace(this.host, 'host.hiden') + path)}`);
|
logger.debug(`...URI: ${encodeURI(this.baseUrl.replace(this.host, 'host.hiden') + path)}`);
|
||||||
|
if (conf.ssl === "true")
|
||||||
logger.debug(`...rejectUnauthorized: ${options["https"]["rejectUnauthorized"]}`);
|
logger.debug(`...rejectUnauthorized: ${options["https"]["rejectUnauthorized"]}`);
|
||||||
pipeline(
|
pipeline(
|
||||||
got.stream.get(encodeURI(this.baseUrl + path), options)
|
got.stream.get(encodeURI(this.baseUrl + path), options)
|
||||||
|
Loading…
Reference in New Issue
Block a user