Fix failure when using --nodownload

This commit is contained in:
Ben Peddell 2016-11-29 07:30:04 +10:00
parent a5d3fd72c2
commit 6f244a02fa

View File

@ -1597,17 +1597,17 @@ doUpdate() {
echo "Update download interrupted"
return 1
fi
fi
local curver="$(getCurrentVersion)"
local newver="$(getStagingVersion)"
local nextver="$(getAvailableVersion)"
if [[ -z "${newver}" || "$curver" == "$newver" ]]; then
if [ -z "$force" ]; then
echo "Update download unsuccessful"
return 1
elif [ "${newver}" != "${nextver}" ]; then
echo "Warning: staging directory update was unsuccessful"
local curver="$(getCurrentVersion)"
local newver="$(getStagingVersion)"
local nextver="$(getAvailableVersion)"
if [[ -z "${newver}" || "$curver" == "$newver" ]]; then
if [ -z "$force" ]; then
echo "Update download unsuccessful"
return 1
elif [ "${newver}" != "${nextver}" ]; then
echo "Warning: staging directory update was unsuccessful"
fi
fi
fi
fi