Skip to content

Commit b6c670a

Browse files
committed
Rename guzzle option to requestOptions
1 parent 0af98cd commit b6c670a

File tree

4 files changed

+7
-7
lines changed

4 files changed

+7
-7
lines changed

doc/services/object-store/v1/objects.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@ Download an object
3232
As you will notice, a Stream_ object is returned by this call. For more information about dealing with streams, please
3333
consult `Guzzle's docs`_.
3434

35-
By default, the whole body of the object is fetched before the function returns, set the ``'guzzle'`` key of parameter
36-
``$data`` to ``['stream' => true]`` to get the stream before the end of download.
35+
By default, the whole body of the object is fetched before the function returns, set the ``'requestOptions'`` key of
36+
parameter ``$data`` to ``['stream' => true]`` to get the stream before the end of download.
3737

3838
.. _Stream: https://github.com/guzzle/streams/blob/master/src/Stream.php
3939
.. _Guzzle's docs: https://guzzle.readthedocs.org/en/5.3/streams.html

src/Common/Api/OperatorTrait.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -112,8 +112,8 @@ protected function sendRequest(Operation $operation, array $userValues = [], boo
112112

113113
$uri = Utils::uri_template($operation->getPath(), $userValues);
114114

115-
if (array_key_exists('guzzle', $userValues)) {
116-
$options += $userValues['guzzle'];
115+
if (array_key_exists('requestOptions', $userValues)) {
116+
$options += $userValues['requestOptions'];
117117
}
118118

119119
return $this->client->$method($operation->getMethod(), $uri, $options);

src/ObjectStore/v1/Models/StorageObject.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -134,8 +134,8 @@ public function retrieve()
134134
* This call will perform a `GET` HTTP request for the given object and return back its content in the form of a
135135
* Guzzle Stream object. Downloading an object will transfer all of the content for an object, and is therefore
136136
* distinct from fetching its metadata (a `HEAD` request). The whole body of the object is fetched before the
137-
* function returns, set the `'guzzle'` key of {@param $data} to `['stream' => true]` to get the stream before the
138-
* end of download.
137+
* function returns, set the `'requestOptions'` key of {@param $data} to `['stream' => true]` to get the stream
138+
* before the end of download.
139139
*
140140
* @param array $data {@see \OpenStack\ObjectStore\v1\Api::getObject}
141141
*/

tests/unit/Common/Api/OperatorTraitTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ public function test_guzzle_options_are_forwarded()
111111
$this->client->request('GET', 'test', ['headers' => [], 'stream' => true])->willReturn(new Response());
112112

113113
$this->operator->execute($this->def, [
114-
'guzzle' => ['stream' => true]
114+
'requestOptions' => ['stream' => true]
115115
]);
116116

117117
$this->addToAssertionCount(1);

0 commit comments

Comments
 (0)