1
0
Fork 0
forked from mirror/pixelfed

Update StatusService, fix bug in getFull method

This commit is contained in:
Daniel Supernault 2023-05-24 23:41:48 -06:00
parent 88f7dc26bb
commit 4d8b4dcf35
No known key found for this signature in database
GPG key ID: 0DEF1C662C9033F7

View file

@ -121,6 +121,9 @@ class StatusService
public static function getFull($id, $pid, $publicOnly = true) public static function getFull($id, $pid, $publicOnly = true)
{ {
$res = self::get($id, $publicOnly); $res = self::get($id, $publicOnly);
if(!$res || !isset($res['account']) || !isset($res['account']['id'])) {
return $res;
}
$res['relationship'] = RelationshipService::get($pid, $res['account']['id']); $res['relationship'] = RelationshipService::get($pid, $res['account']['id']);
return $res; return $res;
} }