add exit code to validate_domain function

This commit is contained in:
Matthew Saunders Brown 2024-02-12 10:44:45 -08:00
parent bf7407584c
commit 766a99478b

View File

@ -174,7 +174,7 @@ function pdns:getoptions () {
fi fi
if ! pdns::validate_domain $zone; then if ! pdns::validate_domain $zone; then
echo "ERROR: $zone is not a valid domain name." echo "ERROR: $zone is not a valid domain name."
exit exit 1
fi fi
;; ;;
e ) # max (integer) Maximum number of entries to return e ) # max (integer) Maximum number of entries to return
@ -228,7 +228,7 @@ function pdns:getoptions () {
fi fi
if ! pdns::validate_domain $zone; then if ! pdns::validate_domain $zone; then
echo "ERROR: $zone is not a valid domain name." echo "ERROR: $zone is not a valid domain name."
exit exit 1
fi fi
;; ;;
\? ) \? )