use is not None for xml.etree.Element

This commit is contained in:
lilydjwg 2019-03-07 17:22:58 +08:00
parent e58142e37f
commit 056fe65e79

View file

@ -45,7 +45,7 @@ async def get_version(name, conf, **kwargs):
continue
for archive in pkg.findall('./archives/archive'):
host_os = archive.find('./host-os')
if host_os and host_os.text != 'linux':
if host_os is not None and host_os.text != 'linux':
continue
archive_url = archive.find('./complete/url').text
# revision