36 lines
741 B
PHP
36 lines
741 B
PHP
<?php
|
|
|
|
namespace App\Http\Requests\Auth;
|
|
|
|
use Illuminate\Foundation\Http\FormRequest;
|
|
|
|
/**
|
|
* Handles backend forgotten password form validation.
|
|
*/
|
|
class ForgotPasswordRequest extends FormRequest
|
|
{
|
|
/**
|
|
* Get the validation rules that apply to the request.
|
|
*
|
|
* @return array<string, mixed>
|
|
*/
|
|
public function rules(): array
|
|
{
|
|
return [
|
|
'email' => 'required|string|email:rfc,strict,dns,spoof,filter',
|
|
];
|
|
}
|
|
|
|
/**
|
|
* Get custom attributes for validator errors.
|
|
*
|
|
* @return array<string, string>
|
|
*/
|
|
#[\Override]
|
|
public function attributes(): array
|
|
{
|
|
return [
|
|
'email' => trans('validation.attributes.email'),
|
|
];
|
|
}
|
|
}
|