Skip to content

Commit

Permalink
rename requestcookies class
Browse files Browse the repository at this point in the history
  • Loading branch information
hacan359 committed Jan 3, 2025
1 parent abc6475 commit 5cb9f0f
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions guide/en/runtime/cookies.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,16 +18,16 @@ private function actionProfile(\Psr\Http\Message\ServerRequestInterface $request
```

In addition to obtaining cookie values directly from the server request, you can also utilize the [yiisoft/request-provider](https://github.com/yiisoft/request-provider)
package, which provides a more structured way to handle cookies through the `\Yiisoft\RequestProvider\RequestCookies`. This approach can simplify your code and improve readability.
package, which provides a more structured way to handle cookies through the `\Yiisoft\RequestProvider\RequestCookieProvider`. This approach can simplify your code and improve readability.

Here’s an example of how to work with cookies using the `\Yiisoft\RequestProvider\RequestCookies`:
Here’s an example of how to work with cookies using the `\Yiisoft\RequestProvider\RequestCookieProvider`:

```php

class MyClass
{
public function __construct(
private \Yiisoft\RequestProvider\RequestCookies $cookies
private \Yiisoft\RequestProvider\RequestCookieProvider $cookies
) {}

public function go(): void
Expand Down

0 comments on commit 5cb9f0f

Please sign in to comment.