Browse Source

Update dns_njalla.sh

the ID was not getting extracted from the record data. The " character was missing.
pull/4354/head
Ecky-Ecky-Pikang-Zoom-Boing-Gumzowehzeh 2 years ago
committed by GitHub
parent
commit
9008248af5
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      dnsapi/dns_njalla.sh

2
dnsapi/dns_njalla.sh

@ -93,7 +93,7 @@ dns_njalla_rm() {
echo "$records" | while read -r record; do echo "$records" | while read -r record; do
record_name=$(echo "$record" | _egrep_o "\"name\":\s?\"[^\"]*\"" | cut -d : -f 2 | tr -d " " | tr -d \") record_name=$(echo "$record" | _egrep_o "\"name\":\s?\"[^\"]*\"" | cut -d : -f 2 | tr -d " " | tr -d \")
record_content=$(echo "$record" | _egrep_o "\"content\":\s?\"[^\"]*\"" | cut -d : -f 2 | tr -d " " | tr -d \") record_content=$(echo "$record" | _egrep_o "\"content\":\s?\"[^\"]*\"" | cut -d : -f 2 | tr -d " " | tr -d \")
record_id=$(echo "$record" | _egrep_o "\"id\":\s?[0-9]+" | cut -d : -f 2 | tr -d " " | tr -d \")
record_id=$(echo "$record" | _egrep_o "\"id\":\s?\"[0-9]+" | cut -d : -f 2 | tr -d " " | tr -d \")
if [ "$_sub_domain" = "$record_name" ]; then if [ "$_sub_domain" = "$record_name" ]; then
if [ "$txtvalue" = "$record_content" ]; then if [ "$txtvalue" = "$record_content" ]; then
_debug "record_id" "$record_id" _debug "record_id" "$record_id"

Loading…
Cancel
Save