Fix: FindProxyForURL function

This commit is contained in:
Gregory Lirent 2024-05-30 01:34:23 +03:00
parent 388d4c657e
commit e702f608cd
Signed by: lirent
GPG Key ID: F616BE337EFFEE77

View File

@ -122,7 +122,7 @@ class PACContent:
for proxy in self.proxies:
if proxy.is_allowed_from(net):
f_blocks.append(proxy.render())
p_blocks.append(f'\tif ({proxy.function_name}(host) return "{str(proxy)}";')
p_blocks.append(f'\tif ({proxy.function_name}(host)) return "{str(proxy)}";')
p_blocks.append('\treturn "DIRECT";\n}')
f_blocks.append("\n".join(p_blocks))