Skip to content

Commit

Permalink
Fix people pictures and return only single image size
Browse files Browse the repository at this point in the history
  • Loading branch information
irfan-dahir committed Oct 1, 2021
1 parent 31ff8d4 commit dc5aea8
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/MyAnimeList/MalClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -400,7 +400,7 @@ public function getPersonPictures(Request\Person\PersonPicturesRequest $request)
{
$crawler = $this->ghoutte->request('GET', $request->getPath());
try {
$parser = new Parser\Common\PicturesPageParser($crawler);
$parser = new Parser\Common\DefaultPicturesPageParser($crawler);

return $parser->getModel();
} catch (\Exception $e) {
Expand Down
2 changes: 1 addition & 1 deletion src/Request/Person/PersonPicturesRequest.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,6 @@ public function __construct(int $id)
public function getPath(): string
{
// MyAnimeList wants <something> after /<id>/... it happily accepts jikan as a valid parameter though
return sprintf('https://myanimelist.net/people/%d/jikan/pictures', $this->id);
return sprintf('https://myanimelist.net/people/%d/jikan/pics', $this->id);
}
}

0 comments on commit dc5aea8

Please sign in to comment.