user()->checkPermission("auth.user:create"); } /** * Get the validation rules that apply to the request. * * @return array|string> */ public function rules(): array { return [ 'name' => 'required|string', 'email' => 'required|string', 'roles' => 'nullable|array', 'roles.*' => 'nullable|integer' ]; } }