fix proxies handling