koel/app/Http/Requests/API/SongUpdateRequest.php
2020-12-22 21:11:22 +01:00

24 lines
438 B
PHP

<?php
namespace App\Http\Requests\API;
/**
* @property array<string> $songs
* @property array<mixed> $data
*/
class SongUpdateRequest extends Request
{
public function authorize(): bool
{
return $this->user()->is_admin;
}
/** @return array<mixed> */
public function rules(): array
{
return [
'data' => 'required|array',
'songs' => 'required|array',
];
}
}