code quality fixed

This commit is contained in:
Muzahid 2021-06-19 21:46:55 +05:30
parent 6b62c50925
commit f605a85aa4
Signed by untrusted user: cis-muzahid
GPG Key ID: 1DC85E7D3AB613EA

View File

@ -115,8 +115,8 @@ def encodeHost(host):
return '\xfd\x87\xd8\x7e\xeb\x43' + base64.b32decode(
host.split(".")[0], True)
except TypeError:
return '\xfd\x87\xd8\x7e\xeb\x43' + base64.b32decode(
host.split(".")[0], True).decode('utf-8', 'ignore')
return '\xfd\x87\xd8\x7e\xeb\x43' + \
base64.b32decode(host.split(".")[0], True).decode('utf-8', 'ignore')
elif host.find(':') == -1:
try:
return '\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\xFF\xFF' + \