repository = $repository; } /** * Return the current resource utilization for a server. * * @throws \Pterodactyl\Exceptions\Http\Connection\DaemonConnectionException */ public function __invoke(GetServerRequest $request, Server $server): array { $stats = $this->repository->setServer($server)->getDetails(); return $this->fractal->item($stats) ->transformWith($this->getTransformer(StatsTransformer::class)) ->toArray(); } }