Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

修复 Python 脚本域名提取错误 #53

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

jinhucheung
Copy link
Contributor

@jinhucheung jinhucheung commented Oct 21, 2019

关联 Issue

#52

问题描述

当 domain.ini 中含有一个二级域名,且它的顶级域已经在列表中定义。此时 Python 脚本调用 getDomain 方法域名没有正确提取

如输入 example.com.cn 至 getDomain, 其会输出 ('example', 'com.cn')

修改描述

调整根域名匹配方式,使用二级域名加顶级域名去匹配根域名列表,若匹配的上,则取上前一个域名,作为主域名,否则当前二级域加顶级域作为主域名

测试

  1. alydns, godaddydns, txydns 三个 python 脚本测试 example.cn, example.com.cn, m.example.com.cn 正常

  2. python2.7 python3.7 测试脚本正常

已测试

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant