| Conditions | 1 |
| Paths | 1 |
| Total Lines | 15 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 0 |
| CRAP Score | 2 |
| Changes | 2 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 24 | public function createClient(): Client |
||
| 25 | { |
||
| 26 | $stack = HandlerStack::create(); |
||
| 27 | |||
| 28 | $stack->push( |
||
| 29 | new CacheMiddleware( |
||
| 30 | new PrivateCacheStrategy( |
||
| 31 | new Psr6CacheStorage( |
||
| 32 | $this->cacheProvider->getCachePool('http') |
||
| 33 | ) |
||
| 34 | ) |
||
| 35 | ) |
||
| 36 | ); |
||
| 37 | |||
| 38 | return new Client(['handler' => $stack]); |
||
| 39 | } |
||
| 41 |