mirror of
https://github.com/pixelfed/pixelfed.git
synced 2024-11-26 08:13:16 +00:00
Update AP Profile Transformer, fix movedTo attribute
This commit is contained in:
parent
25f3fa06af
commit
63100fe950
1 changed files with 4 additions and 1 deletions
|
@ -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'];
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue