Skip to content

Commit

Permalink
replaced deprecated 'stream_for' method in docs
Browse files Browse the repository at this point in the history
  • Loading branch information
to23mas authored and f3l1x committed Apr 15, 2024
1 parent e5a799a commit 1759ce0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .docs/decorators.md
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ use Apitte\Core\Decorator\IRequestDecorator;
use Apitte\Core\Exception\Runtime\EarlyReturnResponseException;
use Apitte\Core\Http\ApiRequest;
use Apitte\Core\Http\ApiResponse;
use function GuzzleHttp\Psr7\stream_for;
use GuzzleHttp\Psr7\Utils;
class RequestAuthenticationDecorator implements IRequestDecorator
{
Expand All @@ -105,7 +105,7 @@ class RequestAuthenticationDecorator implements IRequestDecorator
public function decorateRequest(ApiRequest $request, ApiResponse $response): ApiRequest
{
if ($userAuthenticationFailed) {
$body = stream_for(json_encode([
$body = Utils::streamFor(json_encode([
'status' => 'error',
'code' => 403,
'message' => 'Invalid credentials, authentication failed.'
Expand Down

0 comments on commit 1759ce0

Please sign in to comment.