Skip to content
Permalink
Browse files

Merge pull request #2726 from Blfrg/dns_me

fix #2031 dns_me id parse
  • Loading branch information
Neilpang committed Feb 11, 2020
2 parents 51fc853 + eb49127 commit da656caf1e230d676d42cd0c6e0efe4aeca7d62b
Showing with 1 addition and 1 deletion.
  1. +1 −1 dnsapi/dns_me.sh
@@ -114,7 +114,7 @@ _get_root() {
fi

if _contains "$response" "\"name\":\"$h\""; then
_domain_id=$(printf "%s\n" "$response" | _egrep_o "\"id\":[^,]*" | head -n 1 | cut -d : -f 2 | tr -d '}')
_domain_id=$(printf "%s\n" "$response" | cut -c 2- | head -c -2 | sed 's/{.*}//' | sed -r 's/^.*"id":([0-9]+).*$/\1/')
if [ "$_domain_id" ]; then
_sub_domain=$(printf "%s" "$domain" | cut -d . -f 1-$p)
_domain="$h"

0 comments on commit da656ca

Please sign in to comment.
You can’t perform that action at this time.