Merge pull request #1353 from jonnybarnes/1349-webmentions-are-not-showing
Fix processing of profile image for bridgy webmentions
This commit is contained in:
commit
dfe74e7538
1 changed files with 9 additions and 1 deletions
|
@ -109,8 +109,16 @@ class WebMention extends Model
|
|||
/**
|
||||
* Create the photo link.
|
||||
*/
|
||||
public function createPhotoLink(string $url): string
|
||||
public function createPhotoLink(string|array $url): string
|
||||
{
|
||||
if (is_array($url)) {
|
||||
if (! array_key_exists('value', $url)) {
|
||||
return '';
|
||||
}
|
||||
|
||||
$url = $url['value'];
|
||||
}
|
||||
|
||||
$url = normalize_url($url);
|
||||
$host = parse_url($url, PHP_URL_HOST);
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue