From 99ffdf020cb4310a94bbcac5a48ead59a9f5539f Mon Sep 17 00:00:00 2001 From: NewFuture Date: Mon, 4 Sep 2017 21:24:36 +0800 Subject: [PATCH] =?UTF-8?q?DNSPOD=20=E6=A0=B9=E5=9F=9F=E5=90=8D=E8=87=AA?= =?UTF-8?q?=E5=8A=A8=E5=88=A4=E6=96=AD#8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- dns/dnspod.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/dns/dnspod.py b/dns/dnspod.py index 223a1fb0..fed90976 100644 --- a/dns/dnspod.py +++ b/dns/dnspod.py @@ -64,7 +64,6 @@ def request(action, param=None, **params): def get_domain_info(domain): """ 切割域名获取主域名和对应ID - TODO @记录支持 """ domain_split = domain.split('.') if len(domain_split) == 3: # 长度为3 @@ -80,6 +79,8 @@ def get_domain_info(domain): break else: return None, None + if not sub: # root domain根域名https://github.com/NewFuture/DDNS/issues/9 + sub = '@' return did, sub