2019-11-03 20:20:11 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace Pterodactyl\Http\Requests\Api\Client\Servers\Subusers;
|
|
|
|
|
|
|
|
use Pterodactyl\Http\Requests\Api\Client\ClientApiRequest;
|
|
|
|
|
|
|
|
class GetSubuserRequest extends ClientApiRequest
|
|
|
|
{
|
|
|
|
/**
|
|
|
|
* Confirm that a user is able to view subusers for the specified server.
|
|
|
|
*
|
|
|
|
* @return bool
|
|
|
|
*/
|
|
|
|
public function authorize(): bool
|
|
|
|
{
|
2019-11-04 01:13:47 +00:00
|
|
|
return $this->user()->can('user.read', $this->route()->parameter('server'));
|
2019-11-03 20:20:11 +00:00
|
|
|
}
|
|
|
|
}
|