Upgrade to Laravel 9 (#4413)
Co-authored-by: DaneEveritt <dane@daneeveritt.com>
This commit is contained in:
parent
95e15d2c8a
commit
cbcf62086f
573 changed files with 4387 additions and 9411 deletions
|
@ -3,13 +3,11 @@
|
|||
namespace Pterodactyl\Http\Requests\Admin;
|
||||
|
||||
use Pterodactyl\Models\DatabaseHost;
|
||||
use Illuminate\Contracts\Validation\Validator;
|
||||
|
||||
class DatabaseHostFormRequest extends AdminFormRequest
|
||||
{
|
||||
/**
|
||||
* @return mixed
|
||||
*/
|
||||
public function rules()
|
||||
public function rules(): array
|
||||
{
|
||||
if ($this->method() !== 'POST') {
|
||||
return DatabaseHost::getRulesForUpdate($this->route()->parameter('host'));
|
||||
|
@ -20,10 +18,8 @@ class DatabaseHostFormRequest extends AdminFormRequest
|
|||
|
||||
/**
|
||||
* Modify submitted data before it is passed off to the validator.
|
||||
*
|
||||
* @return \Illuminate\Contracts\Validation\Validator
|
||||
*/
|
||||
protected function getValidatorInstance()
|
||||
protected function getValidatorInstance(): Validator
|
||||
{
|
||||
if (!$this->filled('node_id')) {
|
||||
$this->merge(['node_id' => null]);
|
||||
|
|
Reference in a new issue