1
0
Fork 0
forked from mirror/pixelfed

Update ApiV1Controller, wrap ancestor in array

This commit is contained in:
Daniel Supernault 2020-06-18 21:08:13 -06:00
parent 6dd83d32e3
commit 00a96a15f0
No known key found for this signature in database
GPG key ID: 0DEF1C662C9033F7

View file

@ -1534,7 +1534,9 @@ class ApiV1Controller extends Controller
$ancestors = $status->parent();
if($ancestors) {
$ares = new Fractal\Resource\Item($ancestors, new StatusTransformer());
$ancestors = $this->fractal->createData($ares)->toArray();
$ancestors = [
$this->fractal->createData($ares)->toArray()
];
} else {
$ancestors = [];
}