@@ -182,7 +182,7 @@ discard block |
||
| 182 | 182 | |
| 183 | 183 | /** |
| 184 | 184 | * Get production compagnies |
| 185 | - * @return \Generator|Company |
|
| 185 | + * @return \Generator |
|
| 186 | 186 | */ |
| 187 | 187 | public function getProductionCompanies() : \Generator |
| 188 | 188 | { |
@@ -201,7 +201,7 @@ discard block |
||
| 201 | 201 | |
| 202 | 202 | /** |
| 203 | 203 | * Get production countries |
| 204 | - * @return \Generator|\stdClass |
|
| 204 | + * @return \Generator |
|
| 205 | 205 | */ |
| 206 | 206 | public function getProductionCountries() : \Generator |
| 207 | 207 | { |
@@ -218,7 +218,7 @@ discard block |
||
| 218 | 218 | |
| 219 | 219 | /** |
| 220 | 220 | * Get image backdrops list |
| 221 | - * @return \Generator|Results\Image |
|
| 221 | + * @return \Generator |
|
| 222 | 222 | */ |
| 223 | 223 | public function getBackdrops() : \Generator |
| 224 | 224 | { |
@@ -232,7 +232,7 @@ discard block |
||
| 232 | 232 | |
| 233 | 233 | /** |
| 234 | 234 | * Get image posters list |
| 235 | - * @return \Generator|Results\Image |
|
| 235 | + * @return \Generator |
|
| 236 | 236 | */ |
| 237 | 237 | public function getPosters() : \Generator |
| 238 | 238 | { |
@@ -246,7 +246,7 @@ discard block |
||
| 246 | 246 | |
| 247 | 247 | /** |
| 248 | 248 | * Get similar movies from current movie |
| 249 | - * @return \Generator|Results\Movie |
|
| 249 | + * @return \Generator |
|
| 250 | 250 | */ |
| 251 | 251 | public function getSimilar() : \Generator |
| 252 | 252 | { |
@@ -49,7 +49,8 @@ discard block |
||
| 49 | 49 | */ |
| 50 | 50 | public function getGenres() : array |
| 51 | 51 | { |
| 52 | - if (isset($this->data->genres)) { |
|
| 52 | + if (isset($this->data->genres)) |
|
| 53 | + { |
|
| 53 | 54 | return $this->data->genres; |
| 54 | 55 | } |
| 55 | 56 | return []; |
@@ -61,7 +62,8 @@ discard block |
||
| 61 | 62 | */ |
| 62 | 63 | public function getTitle() : string |
| 63 | 64 | { |
| 64 | - if (isset($this->data->title)) { |
|
| 65 | + if (isset($this->data->title)) |
|
| 66 | + { |
|
| 65 | 67 | return $this->data->title; |
| 66 | 68 | } |
| 67 | 69 | return ''; |
@@ -73,7 +75,8 @@ discard block |
||
| 73 | 75 | */ |
| 74 | 76 | public function getOverview() : string |
| 75 | 77 | { |
| 76 | - if (isset($this->data->overview)) { |
|
| 78 | + if (isset($this->data->overview)) |
|
| 79 | + { |
|
| 77 | 80 | return $this->data->overview; |
| 78 | 81 | } |
| 79 | 82 | return ''; |
@@ -85,7 +88,8 @@ discard block |
||
| 85 | 88 | */ |
| 86 | 89 | public function getReleaseDate() : string |
| 87 | 90 | { |
| 88 | - if (isset($this->data->release_date)) { |
|
| 91 | + if (isset($this->data->release_date)) |
|
| 92 | + { |
|
| 89 | 93 | return $this->data->release_date; |
| 90 | 94 | } |
| 91 | 95 | return ''; |
@@ -97,7 +101,8 @@ discard block |
||
| 97 | 101 | */ |
| 98 | 102 | public function getOriginalTitle() : string |
| 99 | 103 | { |
| 100 | - if (isset($this->data->original_title)) { |
|
| 104 | + if (isset($this->data->original_title)) |
|
| 105 | + { |
|
| 101 | 106 | return $this->data->original_title; |
| 102 | 107 | } |
| 103 | 108 | return ''; |
@@ -109,7 +114,8 @@ discard block |
||
| 109 | 114 | */ |
| 110 | 115 | public function getNote() : float |
| 111 | 116 | { |
| 112 | - if (isset($this->data->vote_average)) { |
|
| 117 | + if (isset($this->data->vote_average)) |
|
| 118 | + { |
|
| 113 | 119 | return $this->data->vote_average; |
| 114 | 120 | } |
| 115 | 121 | return 0; |
@@ -130,7 +136,8 @@ discard block |
||
| 130 | 136 | */ |
| 131 | 137 | public function getIMDBId() : string |
| 132 | 138 | { |
| 133 | - if (isset($this->data->imdb_id)) { |
|
| 139 | + if (isset($this->data->imdb_id)) |
|
| 140 | + { |
|
| 134 | 141 | return $this->data->imdb_id; |
| 135 | 142 | } |
| 136 | 143 | return ''; |
@@ -142,7 +149,8 @@ discard block |
||
| 142 | 149 | */ |
| 143 | 150 | public function getTagLine() : string |
| 144 | 151 | { |
| 145 | - if (isset($this->data->tagline)) { |
|
| 152 | + if (isset($this->data->tagline)) |
|
| 153 | + { |
|
| 146 | 154 | return $this->data->tagline; |
| 147 | 155 | } |
| 148 | 156 | return ''; |
@@ -154,7 +162,8 @@ discard block |
||
| 154 | 162 | */ |
| 155 | 163 | public function getCollectionId() : int |
| 156 | 164 | { |
| 157 | - if (!empty($this->data->belongs_to_collection)) { |
|
| 165 | + if (!empty($this->data->belongs_to_collection)) |
|
| 166 | + { |
|
| 158 | 167 | return (int) $this->data->belongs_to_collection->id; |
| 159 | 168 | } |
| 160 | 169 | return 0; |
@@ -186,8 +195,10 @@ discard block |
||
| 186 | 195 | */ |
| 187 | 196 | public function getProductionCompanies() : \Generator |
| 188 | 197 | { |
| 189 | - if (!empty($this->data->production_companies)) { |
|
| 190 | - foreach ($this->data->production_companies as $p) { |
|
| 198 | + if (!empty($this->data->production_companies)) |
|
| 199 | + { |
|
| 200 | + foreach ($this->data->production_companies as $p) |
|
| 201 | + { |
|
| 191 | 202 | $res = new \stdClass(); |
| 192 | 203 | $res->id = $p->id; |
| 193 | 204 | $res->name = $p->name; |
@@ -205,8 +216,10 @@ discard block |
||
| 205 | 216 | */ |
| 206 | 217 | public function getProductionCountries() : \Generator |
| 207 | 218 | { |
| 208 | - if (!empty($this->data->production_countries)) { |
|
| 209 | - foreach ($this->data->production_countries as $c) { |
|
| 219 | + if (!empty($this->data->production_countries)) |
|
| 220 | + { |
|
| 221 | + foreach ($this->data->production_countries as $c) |
|
| 222 | + { |
|
| 210 | 223 | $res = new \stdClass(); |
| 211 | 224 | $res->iso_3166_1 = $c->iso_3166_1; |
| 212 | 225 | $res->name = $c->name; |
@@ -224,7 +237,8 @@ discard block |
||
| 224 | 237 | { |
| 225 | 238 | $data = $this->tmdb->getRequest('movie/' . (int) $this->id . '/images', $this->params); |
| 226 | 239 | |
| 227 | - foreach ($data->backdrops as $b) { |
|
| 240 | + foreach ($data->backdrops as $b) |
|
| 241 | + { |
|
| 228 | 242 | $image = new Results\Image($this->tmdb, $this->id, $b); |
| 229 | 243 | yield $image; |
| 230 | 244 | } |
@@ -238,7 +252,8 @@ discard block |
||
| 238 | 252 | { |
| 239 | 253 | $data = $this->tmdb->getRequest('movie/' . (int) $this->id . '/images', $this->params); |
| 240 | 254 | |
| 241 | - foreach ($data->posters as $b) { |
|
| 255 | + foreach ($data->posters as $b) |
|
| 256 | + { |
|
| 242 | 257 | $image = new Results\Image($this->tmdb, $this->id, $b); |
| 243 | 258 | yield $image; |
| 244 | 259 | } |
@@ -252,7 +267,8 @@ discard block |
||
| 252 | 267 | { |
| 253 | 268 | $data = $this->tmdb->getRequest('movie/' . (int) $this->id . '/similar', $this->params); |
| 254 | 269 | |
| 255 | - foreach ($data->results as $s) { |
|
| 270 | + foreach ($data->results as $s) |
|
| 271 | + { |
|
| 256 | 272 | $movie = new Results\Movie($this->tmdb, $s); |
| 257 | 273 | yield $movie; |
| 258 | 274 | } |
@@ -47,7 +47,7 @@ discard block |
||
| 47 | 47 | |
| 48 | 48 | /** |
| 49 | 49 | * Crew |
| 50 | - * @return \Generator|Results\Crew |
|
| 50 | + * @return \Generator |
|
| 51 | 51 | */ |
| 52 | 52 | public function getCrew() : \Generator |
| 53 | 53 | { |
@@ -61,7 +61,7 @@ discard block |
||
| 61 | 61 | |
| 62 | 62 | /** |
| 63 | 63 | * Cast |
| 64 | - * @return \Generator|Results\Cast |
|
| 64 | + * @return \Generator |
|
| 65 | 65 | */ |
| 66 | 66 | public function getCast() : \Generator |
| 67 | 67 | { |
@@ -51,8 +51,10 @@ discard block |
||
| 51 | 51 | */ |
| 52 | 52 | public function getCrew() : \Generator |
| 53 | 53 | { |
| 54 | - if (!empty($this->data->crew)) { |
|
| 55 | - foreach ($this->data->crew as $c) { |
|
| 54 | + if (!empty($this->data->crew)) |
|
| 55 | + { |
|
| 56 | + foreach ($this->data->crew as $c) |
|
| 57 | + { |
|
| 56 | 58 | $crew = new Results\Crew($this->tmdb, $c); |
| 57 | 59 | yield $crew; |
| 58 | 60 | } |
@@ -65,8 +67,10 @@ discard block |
||
| 65 | 67 | */ |
| 66 | 68 | public function getCast() : \Generator |
| 67 | 69 | { |
| 68 | - if (!empty($this->data->cast)) { |
|
| 69 | - foreach ($this->data->cast as $c) { |
|
| 70 | + if (!empty($this->data->cast)) |
|
| 71 | + { |
|
| 72 | + foreach ($this->data->cast as $c) |
|
| 73 | + { |
|
| 70 | 74 | $cast = new Results\Cast($this->tmdb, $c); |
| 71 | 75 | yield $cast; |
| 72 | 76 | } |
@@ -26,7 +26,7 @@ |
||
| 26 | 26 | { |
| 27 | 27 | /** |
| 28 | 28 | * Get crew of TV Episode |
| 29 | - * @return \Generator|Results\Crew |
|
| 29 | + * @return \Generator |
|
| 30 | 30 | */ |
| 31 | 31 | public function getCrew() : \Generator |
| 32 | 32 | { |
@@ -30,8 +30,10 @@ |
||
| 30 | 30 | */ |
| 31 | 31 | public function getCrew() : \Generator |
| 32 | 32 | { |
| 33 | - if (!empty($this->data->crew)) { |
|
| 34 | - foreach ($this->data->crew as $crew) { |
|
| 33 | + if (!empty($this->data->crew)) |
|
| 34 | + { |
|
| 35 | + foreach ($this->data->crew as $crew) |
|
| 36 | + { |
|
| 35 | 37 | $crew->gender = null; |
| 36 | 38 | |
| 37 | 39 | $return = new Results\Crew($this->tmdb, $crew); |
@@ -51,9 +51,12 @@ discard block |
||
| 51 | 51 | */ |
| 52 | 52 | public function getMovieList(array $options = array()) : \Generator |
| 53 | 53 | { |
| 54 | - try { |
|
| 54 | + try |
|
| 55 | + { |
|
| 55 | 56 | return $this->getList('genre/movie/list', $options); |
| 56 | - } catch (TmdbException $ex) { |
|
| 57 | + } |
|
| 58 | + catch (TmdbException $ex) |
|
| 59 | + { |
|
| 57 | 60 | throw $ex; |
| 58 | 61 | } |
| 59 | 62 | } |
@@ -66,9 +69,12 @@ discard block |
||
| 66 | 69 | */ |
| 67 | 70 | public function getTVList(array $options = array()) : \Generator |
| 68 | 71 | { |
| 69 | - try { |
|
| 72 | + try |
|
| 73 | + { |
|
| 70 | 74 | return $this->getList('genre/tv/list', $options); |
| 71 | - } catch (TmdbException $ex) { |
|
| 75 | + } |
|
| 76 | + catch (TmdbException $ex) |
|
| 77 | + { |
|
| 72 | 78 | throw $ex; |
| 73 | 79 | } |
| 74 | 80 | } |
@@ -82,17 +88,21 @@ discard block |
||
| 82 | 88 | */ |
| 83 | 89 | private function getList(string $type, array $options) : \Generator |
| 84 | 90 | { |
| 85 | - try { |
|
| 91 | + try |
|
| 92 | + { |
|
| 86 | 93 | $params = $this->tmdb->checkOptions($options); |
| 87 | 94 | $response = $this->tmdb->getRequest($type, $params); |
| 88 | 95 | |
| 89 | 96 | $genres = []; |
| 90 | - if (isset($response->genres)) { |
|
| 97 | + if (isset($response->genres)) |
|
| 98 | + { |
|
| 91 | 99 | $genres = $response->genres; |
| 92 | 100 | } |
| 93 | 101 | |
| 94 | 102 | return $this->genreItemGenerator($genres); |
| 95 | - } catch (TmdbException $ex) { |
|
| 103 | + } |
|
| 104 | + catch (TmdbException $ex) |
|
| 105 | + { |
|
| 96 | 106 | throw $ex; |
| 97 | 107 | } |
| 98 | 108 | } |
@@ -104,7 +114,8 @@ discard block |
||
| 104 | 114 | */ |
| 105 | 115 | private function genreItemGenerator(array $results) : \Generator |
| 106 | 116 | { |
| 107 | - foreach ($results as $result) { |
|
| 117 | + foreach ($results as $result) |
|
| 118 | + { |
|
| 108 | 119 | yield $result; |
| 109 | 120 | } |
| 110 | 121 | } |
@@ -50,13 +50,16 @@ discard block |
||
| 50 | 50 | */ |
| 51 | 51 | public function getList(array $options = array()) : \Generator |
| 52 | 52 | { |
| 53 | - try { |
|
| 53 | + try |
|
| 54 | + { |
|
| 54 | 55 | $params = $this->tmdb->checkOptions($options); |
| 55 | 56 | $response = $this->tmdb->getRequest('job/list', $params); |
| 56 | 57 | |
| 57 | 58 | $results = []; |
| 58 | - if (isset($response->jobs)) { |
|
| 59 | - foreach ($response->jobs as $j) { |
|
| 59 | + if (isset($response->jobs)) |
|
| 60 | + { |
|
| 61 | + foreach ($response->jobs as $j) |
|
| 62 | + { |
|
| 60 | 63 | $result = new \stdClass(); |
| 61 | 64 | $result->department = $j->department; |
| 62 | 65 | $result->jobs = $j->job_list; |
@@ -64,7 +67,9 @@ discard block |
||
| 64 | 67 | $results[] = $result; |
| 65 | 68 | } |
| 66 | 69 | } |
| 67 | - } catch (TmdbException $ex) { |
|
| 70 | + } |
|
| 71 | + catch (TmdbException $ex) |
|
| 72 | + { |
|
| 68 | 73 | throw $ex; |
| 69 | 74 | } |
| 70 | 75 | return $this->genreItemGenerator($results); |
@@ -77,7 +82,8 @@ discard block |
||
| 77 | 82 | */ |
| 78 | 83 | private function genreItemGenerator(array $results) : \Generator |
| 79 | 84 | { |
| 80 | - foreach ($results as $result) { |
|
| 85 | + foreach ($results as $result) |
|
| 86 | + { |
|
| 81 | 87 | yield $result; |
| 82 | 88 | } |
| 83 | 89 | } |
@@ -62,7 +62,8 @@ discard block |
||
| 62 | 62 | { |
| 63 | 63 | $logger = new Logger($this->loggerName); |
| 64 | 64 | |
| 65 | - foreach ($this->handlersConfig as $config) { |
|
| 65 | + foreach ($this->handlersConfig as $config) |
|
| 66 | + { |
|
| 66 | 67 | $handler = $this->newHandler($config['class'], $config['params']); |
| 67 | 68 | $logger->pushHandler($handler); |
| 68 | 69 | } |
@@ -80,7 +81,8 @@ discard block |
||
| 80 | 81 | { |
| 81 | 82 | $reflection = new \ReflectionClass($class); |
| 82 | 83 | |
| 83 | - if (!$reflection->implementsInterface('Monolog\Handler\HandlerInterface')) { |
|
| 84 | + if (!$reflection->implementsInterface('Monolog\Handler\HandlerInterface')) |
|
| 85 | + { |
|
| 84 | 86 | throw new \InvalidArgumentException(); |
| 85 | 87 | } |
| 86 | 88 | |
@@ -87,7 +87,8 @@ |
||
| 87 | 87 | */ |
| 88 | 88 | public function __construct(TmdbInterface $tmdb, \stdClass $result) |
| 89 | 89 | { |
| 90 | - if (!isset($result->episode_count)) { |
|
| 90 | + if (!isset($result->episode_count)) |
|
| 91 | + { |
|
| 91 | 92 | $result->episode_count = null; |
| 92 | 93 | } |
| 93 | 94 | parent::__construct($tmdb, $result); |
@@ -96,13 +96,16 @@ discard block |
||
| 96 | 96 | */ |
| 97 | 97 | public function __construct(TmdbInterface $tmdb, \stdClass $result) |
| 98 | 98 | { |
| 99 | - if (!isset($result->overview)) { |
|
| 99 | + if (!isset($result->overview)) |
|
| 100 | + { |
|
| 100 | 101 | $result->overview = null; |
| 101 | 102 | } |
| 102 | - if (!isset($result->production_code)) { |
|
| 103 | + if (!isset($result->production_code)) |
|
| 104 | + { |
|
| 103 | 105 | $result->production_code = null; |
| 104 | 106 | } |
| 105 | - if (!isset($result->guest_stars)) { |
|
| 107 | + if (!isset($result->guest_stars)) |
|
| 108 | + { |
|
| 106 | 109 | $result->guest_stars = null; |
| 107 | 110 | } |
| 108 | 111 | |
@@ -146,8 +149,10 @@ discard block |
||
| 146 | 149 | */ |
| 147 | 150 | public function getGuestStars() : \Generator |
| 148 | 151 | { |
| 149 | - if (isset($this->guest_stars)) { |
|
| 150 | - foreach ($this->guest_stars as $gs) { |
|
| 152 | + if (isset($this->guest_stars)) |
|
| 153 | + { |
|
| 154 | + foreach ($this->guest_stars as $gs) |
|
| 155 | + { |
|
| 151 | 156 | $gs->gender = null; |
| 152 | 157 | $gs->cast_id = null; |
| 153 | 158 | |
@@ -56,7 +56,8 @@ discard block |
||
| 56 | 56 | */ |
| 57 | 57 | public function getGenres() : array |
| 58 | 58 | { |
| 59 | - if (isset($this->data->genres)) { |
|
| 59 | + if (isset($this->data->genres)) |
|
| 60 | + { |
|
| 60 | 61 | return $this->data->genres; |
| 61 | 62 | } |
| 62 | 63 | return []; |
@@ -68,7 +69,8 @@ discard block |
||
| 68 | 69 | */ |
| 69 | 70 | public function getNote() : float |
| 70 | 71 | { |
| 71 | - if (isset($this->data->vote_average)) { |
|
| 72 | + if (isset($this->data->vote_average)) |
|
| 73 | + { |
|
| 72 | 74 | return $this->data->vote_average; |
| 73 | 75 | } |
| 74 | 76 | return 0; |
@@ -80,7 +82,8 @@ discard block |
||
| 80 | 82 | */ |
| 81 | 83 | public function getNumberEpisodes() : int |
| 82 | 84 | { |
| 83 | - if (isset($this->data->number_of_episodes)) { |
|
| 85 | + if (isset($this->data->number_of_episodes)) |
|
| 86 | + { |
|
| 84 | 87 | return $this->data->number_of_episodes; |
| 85 | 88 | } |
| 86 | 89 | return 0; |
@@ -92,7 +95,8 @@ discard block |
||
| 92 | 95 | */ |
| 93 | 96 | public function getNumberSeasons() : int |
| 94 | 97 | { |
| 95 | - if (isset($this->data->number_of_seasons)) { |
|
| 98 | + if (isset($this->data->number_of_seasons)) |
|
| 99 | + { |
|
| 96 | 100 | return $this->data->number_of_seasons; |
| 97 | 101 | } |
| 98 | 102 | return 0; |
@@ -104,7 +108,8 @@ discard block |
||
| 104 | 108 | */ |
| 105 | 109 | public function getOriginalTitle() : string |
| 106 | 110 | { |
| 107 | - if (isset($this->data->original_name)) { |
|
| 111 | + if (isset($this->data->original_name)) |
|
| 112 | + { |
|
| 108 | 113 | return $this->data->original_name; |
| 109 | 114 | } |
| 110 | 115 | return ''; |
@@ -116,7 +121,8 @@ discard block |
||
| 116 | 121 | */ |
| 117 | 122 | public function getOverview() : string |
| 118 | 123 | { |
| 119 | - if (isset($this->data->overview)) { |
|
| 124 | + if (isset($this->data->overview)) |
|
| 125 | + { |
|
| 120 | 126 | return $this->data->overview; |
| 121 | 127 | } |
| 122 | 128 | return ''; |
@@ -128,7 +134,8 @@ discard block |
||
| 128 | 134 | */ |
| 129 | 135 | public function getReleaseDate() : string |
| 130 | 136 | { |
| 131 | - if (isset($this->data->first_air_date)) { |
|
| 137 | + if (isset($this->data->first_air_date)) |
|
| 138 | + { |
|
| 132 | 139 | return $this->data->first_air_date; |
| 133 | 140 | } |
| 134 | 141 | return ''; |
@@ -140,7 +147,8 @@ discard block |
||
| 140 | 147 | */ |
| 141 | 148 | public function getStatus() : string |
| 142 | 149 | { |
| 143 | - if (isset($this->data->status)) { |
|
| 150 | + if (isset($this->data->status)) |
|
| 151 | + { |
|
| 144 | 152 | return $this->data->status; |
| 145 | 153 | } |
| 146 | 154 | return ''; |
@@ -152,7 +160,8 @@ discard block |
||
| 152 | 160 | */ |
| 153 | 161 | public function getTitle() : string |
| 154 | 162 | { |
| 155 | - if (isset($this->data->name)) { |
|
| 163 | + if (isset($this->data->name)) |
|
| 164 | + { |
|
| 156 | 165 | return $this->data->name; |
| 157 | 166 | } |
| 158 | 167 | return ''; |
@@ -164,8 +173,10 @@ discard block |
||
| 164 | 173 | */ |
| 165 | 174 | public function getSeasons() : \Generator |
| 166 | 175 | { |
| 167 | - if (!empty($this->data->seasons)) { |
|
| 168 | - foreach ($this->data->seasons as $season) { |
|
| 176 | + if (!empty($this->data->seasons)) |
|
| 177 | + { |
|
| 178 | + foreach ($this->data->seasons as $season) |
|
| 179 | + { |
|
| 169 | 180 | $season = new Results\TVSeason($this->tmdb, $season); |
| 170 | 181 | yield $season; |
| 171 | 182 | } |
@@ -178,8 +189,10 @@ discard block |
||
| 178 | 189 | */ |
| 179 | 190 | public function getNetworks() : \Generator |
| 180 | 191 | { |
| 181 | - if (!empty($this->data->networks)) { |
|
| 182 | - foreach ($this->data->networks as $network) { |
|
| 192 | + if (!empty($this->data->networks)) |
|
| 193 | + { |
|
| 194 | + foreach ($this->data->networks as $network) |
|
| 195 | + { |
|
| 183 | 196 | $n = new \stdClass(); |
| 184 | 197 | $n->id = $network->id; |
| 185 | 198 | $n->name = $network->name; |
@@ -197,7 +210,8 @@ discard block |
||
| 197 | 210 | { |
| 198 | 211 | $data = $this->tmdb->getRequest('tv/' . (int) $this->id . '/images', $this->params); |
| 199 | 212 | |
| 200 | - foreach ($data->backdrops as $b) { |
|
| 213 | + foreach ($data->backdrops as $b) |
|
| 214 | + { |
|
| 201 | 215 | $image = new Results\Image($this->tmdb, $this->id, $b); |
| 202 | 216 | yield $image; |
| 203 | 217 | } |
@@ -211,7 +225,8 @@ discard block |
||
| 211 | 225 | { |
| 212 | 226 | $data = $this->tmdb->getRequest('tv/' . (int) $this->id . '/images', $this->params); |
| 213 | 227 | |
| 214 | - foreach ($data->posters as $b) { |
|
| 228 | + foreach ($data->posters as $b) |
|
| 229 | + { |
|
| 215 | 230 | $image = new Results\Image($this->tmdb, $this->id, $b); |
| 216 | 231 | yield $image; |
| 217 | 232 | } |
@@ -225,7 +240,8 @@ discard block |
||
| 225 | 240 | { |
| 226 | 241 | $similar = $this->tmdb->getRequest('tv/' . (int) $this->id . '/similar', $this->params); |
| 227 | 242 | |
| 228 | - foreach ($similar->results as $t) { |
|
| 243 | + foreach ($similar->results as $t) |
|
| 244 | + { |
|
| 229 | 245 | $tvshow = new Results\TVShow($this->tmdb, $t); |
| 230 | 246 | yield $tvshow; |
| 231 | 247 | } |