Remove debug call and change how connect_timeout is set
This commit is contained in:
parent
f0480c34d7
commit
fb492d4bb2
@ -122,11 +122,12 @@ class HTTPClient extends HTTP_Request2
|
|||||||
// responses... But the default in HTTP_Request2 is 0 for
|
// responses... But the default in HTTP_Request2 is 0 for
|
||||||
// some reason and should probably be considered a valid value.
|
// some reason and should probably be considered a valid value.
|
||||||
$this->config['timeout'] = common_config('http', 'timeout');
|
$this->config['timeout'] = common_config('http', 'timeout');
|
||||||
common_debug('Using HTTPClient timeout value of '._ve($this->config['timeout']));
|
|
||||||
} else {
|
} else {
|
||||||
common_log(LOG_ERR, 'config option http/timeout is not an integer value: '._ve(common_config('http', 'timeout')));
|
common_log(LOG_ERR, 'config option http/timeout is not an integer value: '._ve(common_config('http', 'timeout')));
|
||||||
}
|
}
|
||||||
$this->config['connect_timeout'] = common_config('http', 'connect_timeout') ?: $this->config['connect_timeout'];
|
if (!empty(common_config('http', 'connect_timeout'))) {
|
||||||
|
$this->config['connect_timeout'] = common_config('http', 'connect_timeout');
|
||||||
|
}
|
||||||
$this->config['max_redirs'] = 10;
|
$this->config['max_redirs'] = 10;
|
||||||
$this->config['follow_redirects'] = true;
|
$this->config['follow_redirects'] = true;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user