Pint
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
|
||||
namespace App\Http\Requests\Auth;
|
||||
|
||||
use GrantHolle\Altcha\Rules\ValidAltcha;
|
||||
use Illuminate\Auth\Events\Lockout;
|
||||
use Illuminate\Foundation\Http\FormRequest;
|
||||
use Illuminate\Support\Facades\Auth;
|
||||
@@ -9,8 +10,6 @@ use Illuminate\Support\Facades\RateLimiter;
|
||||
use Illuminate\Support\Str;
|
||||
use Illuminate\Validation\ValidationException;
|
||||
|
||||
use GrantHolle\Altcha\Rules\ValidAltcha;
|
||||
|
||||
class LoginRequest extends FormRequest
|
||||
{
|
||||
/**
|
||||
@@ -31,7 +30,7 @@ class LoginRequest extends FormRequest
|
||||
return [
|
||||
'email' => ['required', 'string', 'email'],
|
||||
'password' => ['required', 'string'],
|
||||
'altcha' => ['required', new ValidAltcha],
|
||||
'altcha' => ['required', new ValidAltcha],
|
||||
];
|
||||
}
|
||||
|
||||
|
||||
@@ -12,7 +12,8 @@ class MatrixRegisterRequest extends FormRequest
|
||||
public function authorize(): bool
|
||||
{
|
||||
$isOldEnough = $this->user()->created_at->lt(now()->subMonth());
|
||||
$noAccount = !$this->user()->matrix_id;
|
||||
$noAccount = ! $this->user()->matrix_id;
|
||||
|
||||
return $isOldEnough && $noAccount;
|
||||
}
|
||||
|
||||
|
||||
@@ -21,7 +21,7 @@ class ProfileUpdateRequest extends FormRequest
|
||||
'nullable',
|
||||
'image',
|
||||
'mimes:jpg,png,jpeg,webp,gif',
|
||||
'max:8192'
|
||||
'max:8192',
|
||||
],
|
||||
'email' => [
|
||||
'required',
|
||||
|
||||
Reference in New Issue
Block a user