From 3b7eee439360e5ff560a5612b1f8b6bd77b14011 Mon Sep 17 00:00:00 2001 From: Serghey Rodin Date: Mon, 16 Jun 2014 12:28:33 +0300 Subject: [PATCH] Fixed NameServer validation bug --- func/domain.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/func/domain.sh b/func/domain.sh index 1bf1cde8..fc10c38d 100644 --- a/func/domain.sh +++ b/func/domain.sh @@ -491,9 +491,9 @@ is_dns_nameserver_valid() { if [ ! -z "$remote" ]; then zone=$USER_DATA/dns/$d.conf a_record=$(echo $r |cut -f 1 -d '.') - record=$(grep "RECORD='$a_record'" $zone| grep "TYPE='A'") - if [ -z "$record" ]; then - echo "Error: corresponding A record $a_record.$d is not exist" + n_record=$(grep "RECORD='$a_record'" $zone| grep "TYPE='A'") + if [ -z "$n_record" ]; then + echo "Error: corresponding A record $a_record.$d does not exist" log_event "$E_NOTEXIST" "$EVENT" exit $E_NOTEXIST fi