New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Stream::getContents() unexpected behavior #38
Comments
If you need to seek and store the entire stream in memory then cast the stream to a string using (string)
|
Well, I think |
The For example, I have called Related: Guzzlehttp - How get the body of a response from Guzzle 6?
vs
|
Hello, I hit one problem when use instance of
GuzzleHttp\Psr7\Stream
.method returns me empty string, although the logger show me correct response.
The problem was that the logger use
(string) $response->getBody()
and we seek to the end of stream.Should we seek back before returns content?
Seems
__toString()
can callgetContent()
.The text was updated successfully, but these errors were encountered: