Exit instead of return if no package name is given
This commit is contained in:
parent
9f999b6887
commit
bb67f0ac37
|
@ -30,7 +30,8 @@ function install_snap {
|
|||
snap_package="$1"
|
||||
|
||||
if [ ! "$snap_package" ]; then
|
||||
return
|
||||
echo $'No snap package was specified'
|
||||
exit 257625472
|
||||
fi
|
||||
no_of_snaps=$(df | grep -c "/snap/core/")
|
||||
if [ "$no_of_snaps" -eq 0 ]; then
|
||||
|
@ -46,7 +47,8 @@ function remove_snap {
|
|||
snap_package="$1"
|
||||
|
||||
if [ ! "$snap_package" ]; then
|
||||
return
|
||||
echo $'No snap package was specified'
|
||||
exit 45332485421
|
||||
fi
|
||||
|
||||
snap remove "$snap_package"
|
||||
|
|
Loading…
Reference in New Issue