From e8ddae45c3b0d05ffac74c6532ce9a314d55bf15 Mon Sep 17 00:00:00 2001 From: Martin Sandford Date: Tue, 28 Apr 2020 20:05:37 +0100 Subject: [PATCH] fix extracting the id from the get response during record deletion --- dnsapi/dns_cf.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dnsapi/dns_cf.sh b/dnsapi/dns_cf.sh index ae1a4e6f..c561629a 100755 --- a/dnsapi/dns_cf.sh +++ b/dnsapi/dns_cf.sh @@ -120,7 +120,7 @@ dns_cf_rm() { if [ "$count" = "0" ]; then _info "Don't need to remove." else - record_id=$(printf "%s\n" "$response" | _egrep_o "\"id\":\"[^\"]*\"" | cut -d : -f 2 | tr -d \" | head -n 1) + record_id=$(printf "%s\n" "$response" | _egrep_o "\"id\":\ \"[^\"]*\"" | cut -d : -f 2 | tr -d \" | head -n 1) _debug "record_id" "$record_id" if [ -z "$record_id" ]; then _err "Can not get record id to remove."