refactor(quickget): remove single use function error_not_supported_os()

This commit is contained in:
Martin Wimpress 2024-05-07 11:10:24 +01:00 committed by Martin Wimpress
parent 46b981728d
commit e1a46b9b5a

View File

@ -148,7 +148,9 @@ function error_specify_os() {
function os_supported() {
if [[ ! "$(os_support)" =~ ${OS} ]]; then
error_not_supported_os
echo -e "ERROR! ${OS} is not a supported OS.\n"
os_support | fold -s -w "$(tput cols)"
exit 1
fi
}
@ -195,12 +197,6 @@ function error_specify_path() {
exit 1
}
function error_not_supported_os() {
echo -e "ERROR! ${OS} is not a supported OS.\n"
os_support | fold -s -w "$(tput cols)"
exit 1
}
function error_not_supported_release() {
if [[ ! "${RELEASES[*]}" =~ ${RELEASE} ]]; then
echo -e "ERROR! ${DISPLAY_NAME} ${RELEASE} is not a supported release."