Update client API endpoints to not use deprecated function
This commit is contained in:
parent
7543ef085d
commit
b99ea53ca1
8 changed files with 74 additions and 58 deletions
|
@ -14,11 +14,12 @@ class ServerController extends ClientApiController
|
|||
* client using the API.
|
||||
*
|
||||
* @param \Pterodactyl\Http\Requests\Api\Client\Servers\GetServerRequest $request
|
||||
* @param \Pterodactyl\Models\Server $server
|
||||
* @return array
|
||||
*/
|
||||
public function index(GetServerRequest $request): array
|
||||
public function index(GetServerRequest $request, Server $server): array
|
||||
{
|
||||
return $this->fractal->item($request->getModel(Server::class))
|
||||
return $this->fractal->item($server)
|
||||
->transformWith($this->getTransformer(ServerTransformer::class))
|
||||
->toArray();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue