<?php
//namespace App\Http\Controllers\Account;
//
//use App\Classes\Modules\ControllersLogic\Accounts\ForgotAccountLogic;
//use App\Http\Controllers\Controller;
//use Illuminate\Http\JsonResponse;
//use Illuminate\Http\RedirectResponse;
//use Illuminate\Http\Request;
//
//class ForgotAccountController extends Controller
//{
//    /**
//     * @param Request $request
//     * @param ForgotAccountLogic $logic
//     * @return JsonResponse
//     * @throws \App\Classes\Modules\ControllerLogic\Exceptions\InternalServerErrorException
//     * @throws \App\Classes\Modules\ControllerLogic\Exceptions\MalformedRequestException
//     */
//    public function forgot(Request $request, ForgotAccountLogic $logic): JsonResponse
//    {
//        return $logic->execute($request);
//    }
//}


namespace App\Http\Controllers\Account;

use Illuminate\Support\Facades\Mail;
use Illuminate\Http\Request;
use App\Http\Controllers\Controller;

class ForgotAccountController extends Controller
{
    /**
     * Send an e-mail reminder to the user.
     *
     * @param  Request  $request
     * @param  int  $id
     * @return Response
     */
    public function forgot()
    {

        Mail::send('emails.reminder', ['user' => "ahmad"], function ($m) {
            $m->from('2f114cfc66-6c1272@inbox.mailtrap.io', 'Your Application');

            $m->to("2f114cfc66-6c1272@inbox.mailtrap.io", "ahmad")->subject('Your Reminder!');
        });
    }
}