File tree Expand file tree Collapse file tree 1 file changed +6
-7
lines changed Expand file tree Collapse file tree 1 file changed +6
-7
lines changed Original file line number Diff line number Diff line change @@ -76,7 +76,6 @@ def _clean_host(s: str) -> str:
7676def 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
You can’t perform that action at this time.
0 commit comments