We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 97e68fc commit 8a3de9bCopy full SHA for 8a3de9b
bin/v-change-dns-record
@@ -58,13 +58,17 @@ check_hestia_demo_mode
58
line=$(grep "ID='$id'" $USER_DATA/dns/$domain.conf)
59
parse_object_kv_list "$line"
60
61
+if [ -z $type ]; then
62
+ type=$TYPE
63
+fi
64
+
65
# Null priority for none MX/SRV records
-if [ "$TYPE" != 'MX' ] && [ "$TYPE" != 'SRV' ]; then
66
+if [ "$type" != 'MX' ] && [ "$TYPE" != 'SRV' ]; then
67
priority=''
68
fi
69
70
# Add trailing dot at the end of NS/CNAME/MX/PTR/SRV record
-if [[ $TYPE =~ NS|CNAME|MX|PTR|SRV ]]; then
71
+if [[ $type =~ NS|CNAME|MX|PTR|SRV ]]; then
72
trailing_dot=$(echo $dvalue | grep "\.$")
73
if [ -z $trailing_dot ]; then
74
dvalue="$dvalue."
0 commit comments