mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Lintfix
This commit is contained in:
parent
f52ea0be7c
commit
5932a0d152
1 changed files with 3 additions and 4 deletions
|
@ -156,10 +156,6 @@ class IPv6AddressScoped(ipaddress.IPv6Address):
|
|||
ipaddress._BaseAddress.__init__(self, address)
|
||||
ipaddress._BaseV6.__init__(self, address)
|
||||
else:
|
||||
# This method (below) won't be around for Python 3
|
||||
# and this type is needed to be checked differently
|
||||
self._is_packed_binary = lambda p: isinstance(p, bytes)
|
||||
|
||||
# Python 3.4 fix. Versions higher are simply not affected
|
||||
# https://github.com/python/cpython/blob/3.4/Lib/ipaddress.py#L543-L544
|
||||
self._version = 6
|
||||
|
@ -185,6 +181,9 @@ class IPv6AddressScoped(ipaddress.IPv6Address):
|
|||
:param data:
|
||||
:return:
|
||||
'''
|
||||
if sys.version_info.major > 2:
|
||||
return isinstance(data, bytes)
|
||||
|
||||
packed = False
|
||||
if len(data) == 16 and ':' not in data:
|
||||
try:
|
||||
|
|
Loading…
Add table
Reference in a new issue