mirror of
https://github.com/pixelfed/pixelfed.git
synced 2024-11-22 14:31:26 +00:00
Add API RelationshipTransformer
This commit is contained in:
parent
ac676dba1c
commit
de11fa90af
1 changed files with 25 additions and 0 deletions
25
app/Transformer/Api/RelationshipTransformer.php
Normal file
25
app/Transformer/Api/RelationshipTransformer.php
Normal file
|
@ -0,0 +1,25 @@
|
|||
<?php
|
||||
|
||||
namespace App\Transformer\Api;
|
||||
|
||||
use App\Profile;
|
||||
use League\Fractal;
|
||||
|
||||
class RelationshipTransformer extends Fractal\TransformerAbstract
|
||||
{
|
||||
public function transform(Profile $profile)
|
||||
{
|
||||
return [
|
||||
'id' => $profile->id,
|
||||
'following' => null,
|
||||
'followed_by' => null,
|
||||
'blocking' => null,
|
||||
'muting' => null,
|
||||
'muting_notifications' => null,
|
||||
'requested' => null,
|
||||
'domain_blocking' => null,
|
||||
'showing_reblogs' => null,
|
||||
'endorsed' => null
|
||||
];
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue