aboutsummaryrefslogtreecommitdiff
path: root/lib/contents.php
diff options
context:
space:
mode:
authorGravatar dag <me@dvikan.no> 2022-04-03 09:37:39 +0200
committerGravatar GitHub <noreply@github.com> 2022-04-03 09:37:39 +0200
commitbed20e9f2813c55388ed611d302e44eb0b97d7ef (patch)
treeededa02a30d06f8bbf0ce5d3fe474bcd65b90ded /lib/contents.php
parent42788cd3ee9057a35cdee18659205457fae868db (diff)
downloadrss-bridge-bed20e9f2813c55388ed611d302e44eb0b97d7ef.tar.gz
rss-bridge-bed20e9f2813c55388ed611d302e44eb0b97d7ef.tar.zst
rss-bridge-bed20e9f2813c55388ed611d302e44eb0b97d7ef.zip
feat: extract curl ua to config value (#2568)
* exclude config.default.ini.php from phpcs
Diffstat (limited to 'lib/contents.php')
-rw-r--r--lib/contents.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/contents.php b/lib/contents.php
index ce7d335a..a5591c33 100644
--- a/lib/contents.php
+++ b/lib/contents.php
@@ -168,7 +168,7 @@ function getContents($url, $header = array(), $opts = array(), $returnHeader = f
}
- curl_setopt($ch, CURLOPT_USERAGENT, ini_get('user_agent'));
+ curl_setopt($ch, CURLOPT_USERAGENT, Configuration::getConfig('http', 'useragent'));
curl_setopt($ch, CURLOPT_ENCODING, '');
curl_setopt($ch, CURLOPT_PROTOCOLS, CURLPROTO_HTTP | CURLPROTO_HTTPS);