mirror of
https://github.com/RSS-Bridge/rss-bridge.git
synced 2025-01-09 13:07:27 +03:00
fix: broken if_not_modified_since (#4377)
This commit is contained in:
parent
f0db6a22d1
commit
152e96d3d0
1 changed files with 8 additions and 7 deletions
|
@ -24,6 +24,13 @@ function getContents(
|
|||
|
||||
// TODO: consider url validation at this point
|
||||
|
||||
$config = [
|
||||
'useragent' => Configuration::getConfig('http', 'useragent'),
|
||||
'timeout' => Configuration::getConfig('http', 'timeout'),
|
||||
'retries' => Configuration::getConfig('http', 'retries'),
|
||||
'curl_options' => $curlOptions,
|
||||
];
|
||||
|
||||
$httpHeadersNormalized = [];
|
||||
foreach ($httpHeaders as $httpHeader) {
|
||||
$parts = explode(':', $httpHeader);
|
||||
|
@ -69,13 +76,7 @@ function getContents(
|
|||
'TE' => 'trailers',
|
||||
];
|
||||
|
||||
$config = [
|
||||
'useragent' => Configuration::getConfig('http', 'useragent'),
|
||||
'timeout' => Configuration::getConfig('http', 'timeout'),
|
||||
'retries' => Configuration::getConfig('http', 'retries'),
|
||||
'headers' => array_merge($defaultHttpHeaders, $httpHeadersNormalized),
|
||||
'curl_options' => $curlOptions,
|
||||
];
|
||||
$config['headers'] = array_merge($defaultHttpHeaders, $httpHeadersNormalized);
|
||||
|
||||
$maxFileSize = Configuration::getConfig('http', 'max_filesize');
|
||||
if ($maxFileSize) {
|
||||
|
|
Loading…
Reference in a new issue