ldap: fix truthiness check

main
Marshall Hallenbeck 2023-10-06 12:29:36 -04:00
parent 4ec4672b87
commit f66923b296
1 changed files with 1 additions and 1 deletions

View File

@ -835,7 +835,7 @@ class ldap(connection):
name = str(attribute["vals"][0])
try:
ip_address = socket.gethostbyname(name.split(".")[0])
if ip_address != True and name != "":
if ip_address is not True and name != "":
self.logger.highlight(f"{name} = {colored(ip_address, host_info_colors[0])}")
except socket.gaierror:
self.logger.fail(f"{name} = Connection timeout")