mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-05-25 10:11:53 +02:00
correct check for bashio fs.directory_exists
This commit is contained in:
@@ -10,7 +10,7 @@ declare interface_name=""
|
|||||||
declare openvpn_username
|
declare openvpn_username
|
||||||
declare openvpn_password
|
declare openvpn_password
|
||||||
|
|
||||||
if bashio::file_exists "${OPENVPN_STATE_DIR}"; then
|
if bashio::fs.directory_exists "${OPENVPN_STATE_DIR}"; then
|
||||||
bashio::log.warning "Previous OpenVPN state directory found, cleaning up."
|
bashio::log.warning "Previous OpenVPN state directory found, cleaning up."
|
||||||
rm -Rf "${OPENVPN_STATE_DIR}"
|
rm -Rf "${OPENVPN_STATE_DIR}"
|
||||||
fi
|
fi
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ declare wireguard_config=""
|
|||||||
declare wireguard_runtime_config=""
|
declare wireguard_runtime_config=""
|
||||||
declare interface_name=""
|
declare interface_name=""
|
||||||
|
|
||||||
if bashio::file_exists "${WIREGUARD_STATE_DIR}"; then
|
if bashio::fs.directory_exists "${WIREGUARD_STATE_DIR}"; then
|
||||||
bashio::log.warning "Previous WireGuard state directory found, cleaning up."
|
bashio::log.warning "Previous WireGuard state directory found, cleaning up."
|
||||||
rm -Rf "${WIREGUARD_STATE_DIR}"
|
rm -Rf "${WIREGUARD_STATE_DIR}"
|
||||||
fi
|
fi
|
||||||
|
|||||||
Reference in New Issue
Block a user