function rewind_body in Zircon Profile 8.0
Same name and namespace in other branches
- 8 vendor/guzzlehttp/psr7/src/functions.php \GuzzleHttp\Psr7\rewind_body()
Attempts to rewind a message body and throws an exception on failure.
The body of the message will only be rewound if a call to `tell()` returns a value other than `0`.
Parameters
MessageInterface $message Message to rewind:
Throws
\RuntimeException
File
- vendor/
guzzlehttp/ psr7/ src/ functions.php, line 250
Namespace
GuzzleHttp\Psr7Code
function rewind_body(MessageInterface $message) {
$body = $message
->getBody();
if ($body
->tell()) {
$body
->rewind();
}
}