1
0
mirror of https://github.com/RSS-Bridge/rss-bridge.git synced 2025-08-10 18:44:04 +02:00

bridges: Fix bridges with custom headers and options

This commit fixes bridges which called getContents, getSimpleHTMLDOM
or getSimpleHTMLDOMCached with custom settings.
This commit is contained in:
logmanoriginal
2018-03-25 14:01:35 +02:00
parent ee78e7613f
commit 6caca4946b
4 changed files with 18 additions and 44 deletions

View File

@@ -64,13 +64,11 @@ class Arte7Bridge extends BridgeAbstract {
. $lang
. ($category != null ? '&category.code=' . $category : '');
$context = array(
'http' => array(
'header' => 'Authorization: Bearer '. self::API_TOKEN
)
$header = array(
'Authorization: Bearer ' . self::API_TOKEN
);
$input = getContents($url, false, stream_context_create($context)) or die('Could not request ARTE.');
$input = getContents($url, $header) or die('Could not request ARTE.');
$input_json = json_decode($input, true);
foreach($input_json['videos'] as $element) {