mirror of
https://github.com/jikan-me/jikan-rest.git
synced 2025-02-20 11:23:35 +08:00
v2: add AnimeMoreInfo
This commit is contained in:
parent
abf4c75220
commit
32d6c88f8e
@ -178,7 +178,18 @@ class AnimeController extends Controller
|
||||
|
||||
public function moreInfo(int $id)
|
||||
{
|
||||
$anime = $this->jikan->getAnimeMoreInfo(new AnimeMoreInfoRequest($id));
|
||||
return response($this->serializer->serialize($anime, 'json'));
|
||||
$anime = $this->_main($id);
|
||||
$moreinfo = ['moreinfo' => $this->jikan->getAnimeMoreInfo(new AnimeMoreInfoRequest($id))];
|
||||
$moreinfo = json_decode(
|
||||
$this->serializer->serialize($moreinfo, 'json'),
|
||||
true
|
||||
);
|
||||
|
||||
return response(
|
||||
array_merge(
|
||||
$anime,
|
||||
$moreinfo
|
||||
)
|
||||
);
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user