File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -18,6 +18,8 @@ class OcRestClient extends Client
18
18
private $ noHeader = false ;
19
19
private $ origin ;
20
20
private $ features = [];
21
+ private $ global_options = [];
22
+
21
23
/*
22
24
$config = [
23
25
'url' => 'https://develop.opencast.org/', // The API url of the opencast instance (required)
@@ -58,6 +60,8 @@ public function __construct($config)
58
60
$ this ->features = $ config ['features ' ];
59
61
}
60
62
63
+ $ this ->global_options = $ config ['guzzle ' ] ?: [];
64
+
61
65
parent ::__construct ($ parentConstructorConfig );
62
66
}
63
67
@@ -101,6 +105,7 @@ public function setRequestConnectionTimeout($connectionTimeout)
101
105
102
106
private function addRequestOptions ($ uri , $ options )
103
107
{
108
+ $ globalOptions = $ this ->global_options ;
104
109
105
110
// Perform a temp no header request.
106
111
if ($ this ->noHeader ) {
@@ -150,7 +155,7 @@ private function addRequestOptions($uri, $options)
150
155
}
151
156
}
152
157
153
- $ requestOptions = array_merge ($ generalOptions , $ options );
158
+ $ requestOptions = array_merge ($ generalOptions , $ globalOptions , $ options );
154
159
return $ requestOptions ;
155
160
}
156
161
You can’t perform that action at this time.
0 commit comments