Fix incrementing with anilist
timw4mail/HummingBirdAnimeClient/pipeline/head There was a failure building this commit Details

This commit is contained in:
Timothy Warren 2022-09-22 10:21:09 -04:00
parent 3eac929910
commit 6eeef9c317
2 changed files with 3 additions and 2 deletions

View File

@ -279,12 +279,12 @@ final class Model
*/
private function getMediaId (array $data, string $type = 'ANIME'): ?string
{
if ($data['anilist_id'] !== NULL)
if (isset($data['anilist_id']))
{
return $data['anilist_id'];
}
if ($data['mal_id'] !== NULL)
if (isset($data['mal_id']))
{
return $this->getMediaIdFromMalId($data['mal_id'], mb_strtoupper($type));
}

View File

@ -21,6 +21,7 @@ class FormItem extends AbstractType
{
public string|int $id;
public string|int|NULL $mal_id;
public string|int|NULL $anilist_id;
public ?FormItemData $data;
public function setData(mixed $value): void