Skip to content

Commit c23507e

Browse files
authored
unused parameter removed
Signed-off-by: Aarush289 <[email protected]>
1 parent bd762cd commit c23507e

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed

nettacker/core/hostcheck.py

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,6 @@ def _clean_host(s: str) -> str:
7676
def resolve_quick(
7777
host: str,
7878
timeout_sec: float = 2.0,
79-
try_search_suffixes: bool = True,
8079
allow_single_label: bool = True
8180
) -> tuple[bool, str | None]:
8281
"""
@@ -91,19 +90,19 @@ def resolve_quick(
9190
(True, host_name) on success, (False, None) on failure/timeout.
9291
"""
9392
host = _clean_host(host)
94-
if(is_single_ipv4(host) or is_single_ipv6(host)):
93+
if is_single_ipv4(host) or is_single_ipv6(host):
9594
if(is_ip_literal(host)):
96-
return True , host
97-
return False ,None
95+
return True, host
96+
return False, None
9897

9998
if host.endswith("."):
10099
host = host[:-1]
101100

102-
if(not valid_hostname(host)):
103-
return False , None
101+
if not valid_hostname(host):
102+
return False, None
104103

105104
if "." not in host and not allow_single_label:
106-
return False ,None
105+
return False, None
107106

108107
deadline = time.monotonic() + timeout_sec
109108

0 commit comments

Comments
 (0)