misc_pterodactyl-panel/app/Http/Requests/Api/Application/Users/StoreUserRequest.php
2022-12-14 17:05:46 -07:00

23 lines
548 B
PHP

<?php
namespace Pterodactyl\Http\Requests\Api\Application\Users;
use Pterodactyl\Models\User;
use Pterodactyl\Http\Requests\Api\Application\ApplicationApiRequest;
class StoreUserRequest extends ApplicationApiRequest
{
public function rules(array $rules = null): array
{
$rules = $rules ?? User::getRules();
return collect($rules)->only([
'external_id',
'email',
'username',
'password',
'admin_role_id',
'root_admin',
])->toArray();
}
}