diff --git a/common/HttpClient.php b/common/HttpClient.php index 7b26302..abfb6a8 100644 --- a/common/HttpClient.php +++ b/common/HttpClient.php @@ -237,7 +237,11 @@ class HttpClient $url = str_replace('https://', '', $url); } $explode = explode('/', $url); - return System::gethostbyname(array_shift($explode)); + $first = array_shift($explode); + if (preg_match('/\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}/', $first)) { + return $first; + } + return System::gethostbyname($first); } /**