<?php

namespace App\Http\Controllers\Auth;

use App\Http\Controllers\Controller;
use Illuminate\Foundation\Auth\SendsPasswordResetEmails;
use Illuminate\Http\Request;

class ForgotPasswordController extends Controller
{
    /*
    |--------------------------------------------------------------------------
    | Password Reset Controller
    |--------------------------------------------------------------------------
    |
    | This controller is responsible for handling password reset emails and
    | includes a trait which assists in sending these notifications from
    | your application to your users. Feel free to explore this trait.
    |
     */

    use SendsPasswordResetEmails;

    protected function validateEmail(Request $request)
    {
        $lbl_email = strtolower(__('system.fields.email'));
        $request->validate(
            ['email' => 'required|email'],
            [
                "email.required" => __('validation.required', ['attribute' => $lbl_email]),
                "email.email" => __('validation.custom.invalid', ['attribute' => $lbl_email]),
            ]
        );
    }
}
