Zblerg this doesnt behave as expected, clarify the syntax

This commit is contained in:
Alexandre Aubin 2020-12-19 04:28:03 +01:00
parent da906a0dc9
commit e9c8737bd7
2 changed files with 4 additions and 5 deletions

View file

@ -84,7 +84,7 @@ _INSTALL_APP () {
_LOAD_SNAPSHOT_OR_INSTALL_APP () {
local check_path="$1"
local _install_type=$(path_to_install_type $check_path)
local _install_type="$(path_to_install_type $check_path)"
local snapname="snap_${_install_type}install"
if ! LXC_SNAPSHOT_EXISTS $snapname

View file

@ -397,9 +397,8 @@ default_install_path() {
path_to_install_type() {
local check_path="$1"
[ -z "$check_path" ] && echo "nourl" \
|| [ "$check_path" == "/" ] && echo "root" \
|| echo "subdir"
[ -z "$check_path" ] && { echo "nourl"; return; }
[ "$check_path" == "/" ] && { echo "root"; return; }
echo "subdir"
}