| Conditions | 2 |
| Paths | 5 |
| Total Lines | 14 |
| Code Lines | 10 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 10 |
| CRAP Score | 2 |
| Changes | 0 | ||
| 1 | <?php declare(strict_types = 1); |
||
| 67 | 233 | public function __construct(TmdbInterface $tmdb, int $item_id, array $options, string $item_name) |
|
| 68 | { |
||
| 69 | try { |
||
| 70 | 233 | $this->id = $item_id; |
|
| 71 | 233 | $this->tmdb = $tmdb; |
|
| 72 | 233 | $this->logger = $tmdb->getLogger(); |
|
| 73 | 233 | $this->conf = $this->tmdb->getConfiguration(); |
|
| 74 | 233 | $this->tmdb->checkOptionLanguage($options, $this->params); |
|
| 75 | |||
| 76 | 233 | $this->data = $this->tmdb->getRequest($item_name . '/' . (int) $item_id, $this->params); |
|
| 77 | 5 | } catch (TmdbException $ex) { |
|
| 78 | 1 | throw $ex; |
|
| 79 | } |
||
| 80 | 228 | } |
|
| 81 | } |
||
| 82 |