mirror of https://github.com/pixelfed/pixelfed.git
Add ImportStatus Resource
This commit is contained in:
parent
8c9f4da48a
commit
7dd45c23b7
|
@ -0,0 +1,20 @@
|
|||
<?php
|
||||
|
||||
namespace App\Http\Resources;
|
||||
|
||||
use Illuminate\Http\Request;
|
||||
use Illuminate\Http\Resources\Json\JsonResource;
|
||||
use App\Services\StatusService;
|
||||
|
||||
class ImportStatus extends JsonResource
|
||||
{
|
||||
/**
|
||||
* Transform the resource into an array.
|
||||
*
|
||||
* @return array<string, mixed>
|
||||
*/
|
||||
public function toArray(Request $request): array
|
||||
{
|
||||
return StatusService::get($this->status_id, false);
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue