Fix for ip checking to work with proxy server