Skip to content
Snippets Groups Projects
Commit 460f52f7 authored by Yassine Doghri's avatar Yassine Doghri
Browse files

fix(fediverse): set default castopod avatar url when actor avatar is not present

parent 1c8af755
Branches
Tags
No related merge requests found
......@@ -23,6 +23,10 @@ class Fediverse extends FediverseBaseConfig
*/
public string $noteObject = NoteObject::class;
public string $defaultAvatarImagePath = 'media/castopod-avatar_thumbnail.webp';
public string $defaultAvatarImageMimetype = 'image/webp';
public function __construct()
{
parent::__construct();
......
......@@ -48,7 +48,7 @@ class Actor extends FediverseActor
return $this->podcast->cover->thumbnail_url;
}
return $this->attributes['avatar_image_url'];
return parent::getAvatarImageUrl();
}
public function getAvatarImageMimetype(): string
......@@ -57,6 +57,6 @@ class Actor extends FediverseActor
return $this->podcast->cover->thumbnail_mimetype;
}
return $this->attributes['avatar_image_mimetype'];
return parent::getAvatarImageMimetype();
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment