Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
关联 Issue
#52
问题描述
当 domain.ini 中含有一个二级域名,且它的顶级域已经在列表中定义。此时 Python 脚本调用 getDomain 方法域名没有正确提取
如输入
example.com.cn
至 getDomain, 其会输出('example', 'com.cn')
修改描述
调整根域名匹配方式,使用二级域名加顶级域名去匹配根域名列表,若匹配的上,则取上前一个域名,作为主域名,否则当前二级域加顶级域作为主域名
测试
alydns, godaddydns, txydns 三个 python 脚本测试
example.cn
,example.com.cn
,m.example.com.cn
正常python2.7 python3.7 测试脚本正常
已测试