add clear
This commit is contained in:
@@ -261,9 +261,11 @@ class HttpClient
|
||||
*/
|
||||
private function parseHost(&$url)
|
||||
{
|
||||
$host = empty($this->host) ? $url : $this->host;
|
||||
if ($this->checkIsIp($host)) {
|
||||
return $host;
|
||||
if (!empty($this->host)) {
|
||||
$url = $this->host . '/' . ltrim($url, '/');
|
||||
}
|
||||
if (strpos($url, 'http') === false) {
|
||||
$url = 'https://' . $url;
|
||||
}
|
||||
$host = $this->cutRequestUrl($url);
|
||||
if ($this->checkIsIp($host)) {
|
||||
|
||||
Reference in New Issue
Block a user