1
0
Fork 1
mirror of https://github.com/pixelfed/pixelfed.git synced 2024-12-23 08:14:10 +00:00

Update AP Profile Transformer, fix movedTo attribute

This commit is contained in:
Daniel Supernault 2024-03-08 03:56:53 -07:00
parent 25f3fa06af
commit 63100fe950
No known key found for this signature in database
GPG key ID: 23740873EE6F76A1

View file

@ -65,7 +65,10 @@ class ProfileTransformer extends Fractal\TransformerAbstract
} }
if ($profile->moved_to_profile_id) { if ($profile->moved_to_profile_id) {
$res['movedTo'] = AccountService::get($profile->moved_to_profile_id)['url']; $movedTo = AccountService::get($profile->moved_to_profile_id);
if ($movedTo && isset($movedTo['url'], $movedTo['id'])) {
$res['movedTo'] = $movedTo['url'];
}
} }
} }